[macruby-changes] [5271] MacRuby/trunk/vm.cpp

source_changes at macosforge.org source_changes at macosforge.org
Wed Mar 9 18:00:48 PST 2011


Revision: 5271
          http://trac.macosforge.org/projects/ruby/changeset/5271
Author:   lsansonetti at apple.com
Date:     2011-03-09 18:00:48 -0800 (Wed, 09 Mar 2011)
Log Message:
-----------
make sure the redefined_ops gvars are always read-write, as it was causing a problem in the dead code elimination pass under AOT compilation

Modified Paths:
--------------
    MacRuby/trunk/vm.cpp

Modified: MacRuby/trunk/vm.cpp
===================================================================
--- MacRuby/trunk/vm.cpp	2011-03-10 02:00:13 UTC (rev 5270)
+++ MacRuby/trunk/vm.cpp	2011-03-10 02:00:48 UTC (rev 5271)
@@ -865,9 +865,11 @@
     GlobalVariable *gvar = NULL;
     if (iter == redefined_ops_gvars.end()) {
 	if (create) {
+	    // TODO: if OPTZ_LEVEL is 3, force global variables to always be
+	    // true and read-only.
 	    gvar = new GlobalVariable(*RoxorCompiler::module,
 		    Type::getInt8Ty(context),
-		    ruby_aot_compile ? true : false,
+		    false,
 		    GlobalValue::InternalLinkage,
 		    ConstantInt::get(Type::getInt8Ty(context), 0),
 		    "");
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20110309/3f0466ab/attachment.html>


More information about the macruby-changes mailing list