diff options
author | Alon Zakai <alonzakai@gmail.com> | 2012-01-29 19:39:34 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2012-01-29 19:39:34 -0800 |
commit | 242bc369bdc06641e0811b474287c8a31fe9ffc9 (patch) | |
tree | 9e485687ebafba6292570425cf28a0507f168113 | |
parent | 8efbb37510e08619735217ea6690461d6fd9969e (diff) |
enable poppler in o1 and o2, and some test_emcc fixes
-rwxr-xr-x | tests/runner.py | 10 | ||||
-rw-r--r-- | tools/shared.py | 2 |
2 files changed, 4 insertions, 8 deletions
diff --git a/tests/runner.py b/tests/runner.py index fdeb9b11..ca53962f 100755 --- a/tests/runner.py +++ b/tests/runner.py @@ -4283,15 +4283,12 @@ def process(filename): js_engines=[SPIDERMONKEY_ENGINE]) # V8 issue 1407 def test_poppler(self): - if not self.emcc_args == []: return self.skip('very slow, we only do this in default') - - if self.emcc_args is None: Settings.SAFE_HEAP = 0 # Has variable object + if self.emcc_args is None: return self.skip('very slow, we only do this in emcc runs') Settings.CORRECT_OVERFLOWS = 1 Settings.CORRECT_SIGNS = 1 Building.COMPILER_TEST_OPTS += [ - '-I' + path_from_root('tests', 'libcxx', 'include'), # Avoid libstdc++ linking issue, see libcxx test '-I' + path_from_root('tests', 'freetype', 'include'), '-I' + path_from_root('tests', 'poppler', 'include'), ] @@ -5466,8 +5463,9 @@ Options that are modified or new in %s include: # XXX find a way to test this: assert ('& 255' in generated or '&255' in generated) == (opt_level <= 2), 'corrections should be in opt <= 2' assert ('(__label__)' in generated) == (opt_level <= 1), 'relooping should be in opt >= 2' assert ('assert(STACKTOP < STACK_MAX' in generated) == (opt_level == 0), 'assertions should be in opt == 0' - assert 'var $i;' in generated, 'micro opts should always be on' - if opt_level >= 1: assert 'HEAP8[HEAP32[' in generated, 'eliminator should create compound expressions, and fewer one-time vars' + assert 'var $i;' in generated or 'var $storemerge3;' in generated or 'var $storemerge4;' in generated, 'micro opts should always be on' + if opt_level >= 1: + assert 'HEAP8[HEAP32[' in generated or 'HEAP8[$vla1 + $storemerge4 / 2 | 0]' in generated or 'HEAP8[$vla1 + ($storemerge4 / 2 | 0)]' in generated, 'eliminator should create compound expressions, and fewer one-time vars' assert ('_puts(' in generated) == (opt_level >= 1), 'with opt >= 1, llvm opts are run and they should optimize printf to puts' assert ('function _malloc(bytes) {' in generated) == (not has_malloc), 'If malloc is needed, it should be there, if not not' assert 'function _main() {' in generated, 'Should be unminified, including whitespace' diff --git a/tools/shared.py b/tools/shared.py index 81c7fcf8..14f55221 100644 --- a/tools/shared.py +++ b/tools/shared.py @@ -540,7 +540,6 @@ class Building: llvm-as < /dev/null | opt -std-compile-opts -disable-output -debug-pass=Arguments ''' safe = Settings.USE_TYPED_ARRAYS != 2 or Settings.BUILD_AS_SHARED_LIB or Settings.LINKABLE - print 'LLVM opts, safe?', safe opts = [] if optimization_level > 0: if not safe: @@ -548,7 +547,6 @@ class Building: #opts.append('-O%d' % optimization_level) opts.append('-std-compile-opts') opts.append('-std-link-opts') - print 'Unsafe:', opts else: allow_nonportable = not safe optimize_size = True |