Add command-line option to specify position-independent codegen

This commit is contained in:
Matt Pharr
2011-09-06 11:12:43 -07:00
parent 743d82e935
commit c76ef7b174
3 changed files with 18 additions and 5 deletions

6
ispc.h
View File

@@ -162,7 +162,7 @@ struct Target {
name, if the name is a known target. Returns true if the
target was initialized and false if the name is unknown. */
static bool GetTarget(const char *arch, const char *cpu, const char *isa,
Target *);
bool pic, Target *);
/** Returns a comma-delimited string giving the names of the currently
supported target ISAs. */
@@ -215,8 +215,12 @@ struct Target {
integer multiple of the native vector width, for example if we're
"doubling up" and compiling 8-wide on a 4-wide SSE system. */
int vectorWidth;
/** Indicates whether position independent code should be generated. */
bool generatePIC;
};
/** @brief Structure that collects optimization options
This structure collects all of the options related to optimization of