convert pointers in function arguments to addrspace(3). still there is poroblem with shared memory. need to figure out which one ..
This commit is contained in:
4
stmt.cpp
4
stmt.cpp
@@ -278,7 +278,7 @@ DeclStmt::EmitCode(FunctionEmitContext *ctx) const {
|
||||
int addressSpace;
|
||||
if (sym->type->IsConstType())
|
||||
{
|
||||
#if 0 /* current, addressSpace = 4 generates a compilation fails as it can't be passed as a function arg:S */
|
||||
#if 1 /* current, addressSpace = 4 generates a compilation fails as it can't be passed as a function arg:S */
|
||||
addressSpace = 4; /* constant */
|
||||
#else
|
||||
addressSpace = 0; /* use global for now */
|
||||
@@ -333,7 +333,7 @@ DeclStmt::EmitCode(FunctionEmitContext *ctx) const {
|
||||
sym->storagePtr =
|
||||
new llvm::GlobalVariable(*m->module, llvmTypeUn,
|
||||
sym->type->IsConstType(),
|
||||
llvm::GlobalValue::PrivateLinkage,
|
||||
llvm::GlobalValue::InternalLinkage,
|
||||
cinit,
|
||||
llvm::Twine("local_") +
|
||||
llvm::Twine(sym->pos.first_line) +
|
||||
|
||||
Reference in New Issue
Block a user