Hi Gordon,
On Oct 7, 2007, at 10:31 AM, Gordon Henriksen wrote:
>
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/lib/VMCore/Core.cpp (original)
> +++ llvm/trunk/lib/VMCore/Core.cpp Sun Oct 7 12:31:42 2007
> @@ -557,6 +557,17 @@
> unwrap<GlobalVariable>(GlobalVar)->setThreadLocal(IsThreadLocal !=
> 0);
> }
>
> +int LLVMIsGlobalConstant(LLVMValueRef GlobalVar) {
> + bool res = unwrap<GlobalVariable>(GlobalVar)->isConstant();
> + fprintf(stderr, "LLVMIsConstantGlobal(0x%08x) = %s\n",
> + (int) GlobalVar, res? "YES" : "NO");
This is breaking the build on 64-bit machine:
Core.cpp:567: error: cast from 'LLVMOpaqueValue*' to 'int' loses
precision
Also, please don't leave debugging printf's in.
Thanks,
Evan
>
> + return unwrap<GlobalVariable>(GlobalVar)->isConstant();
> +}
> +
> +void LLVMSetGlobalConstant(LLVMValueRef GlobalVar, int IsConstant) {
> + unwrap<GlobalVariable>(GlobalVar)->setConstant(IsConstant != 0);
> +}
> +
> /*--.. Operations on
> functions .............................................--*/
_______________________________________________
llvm-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits