dropbox/pyston — pull request #223 by lyh-kernel (2014-11-15 14:13:36+00:00)
Title: Fix uninitiated read of >> 3 == 3 (REPL)

Fix the bug of
$ ~/pyston_deps/valgrind-3.10.0-install/bin/valgrind --tool=memcheck --track-origins=yes ./pyston_release
==14909== Memcheck, a memory error detector
==14909== Copyright (C) 2002-2013, and GNU GPL'd, by Julian Seward et al.
==14909== Using Valgrind-3.10.0 and LibVEX; rerun with -h for copyright info
==14909== Command: ./pyston_release
==14909==
Pyston v0.2 (rev 6ee8647681e9), targeting Python 2.7.6
\>> 3 == 3
==14909== Conditional jump or move depends on uninitialised value(s)
==14909== at 0x5CA990: pyston::IRGeneratorImpl::doStmt(pyston::AST*, pyston::ExcInfo) (irgenerator.cpp:2071)
==14909== by 0x5C9B87: pyston::IRGeneratorImpl::run(pyston::CFGBlock const*) (irgenerator.cpp:2442)
==14909== by 0x59550D: pyston::emitBBs(pyston::IRGenState*, char const*, pyston::GuardList&, pyston::GuardList const&, pyston::TypeAnalysis*, pyston::OSREntryDescriptor const*, std::unordered_set, std::equal_to, std::allocator > const&, std::unordered_set, std::equal_to, std::allocator > const&) (irgen.cpp:717)
==14909== by 0x58FDEB: pyston::doCompile(pyston::SourceInfo*, pyston::OSREntryDescriptor const*, pyston::EffortLevel::EffortLevel, pyston::FunctionSpecialization*, std::string) (irgen.cpp:1085)
==14909== by 0x5C5A16: pyston::compileFunction(pyston::CLFunction*, pyston::FunctionSpecialization*, pyston::EffortLevel::EffortLevel, pyston::OSREntryDescriptor const*) (hooks.cpp:194)
==14909== by 0x5C722E: pyston::compileAndRunModule(pyston::AST_Module*, pyston::BoxedModule*) (hooks.cpp:263)
==14909== by 0x672C88: main (jit.cpp:252)
==14909== Uninitialised value was created by a heap allocation
==14909== at 0x4C2B0C5: operator new(unsigned long) (vg_replace_malloc.c:324)
==14909== by 0x672B46: main (jit.cpp:236)
==14909==
==14909== Conditional jump or move depends on uninitialised value(s)
==14909== at 0x5CE033: pyston::IRGeneratorImpl::evalExpr(pyston::AST_expr*, pyston::ExcInfo) (irgenerator.cpp:1062)
==14909== by 0x5CAB7F: doAssign (irgenerator.cpp:1458)
==14909== by 0x5CAB7F: pyston::IRGeneratorImpl::doStmt(pyston::AST*, pyston::ExcInfo) (irgenerator.cpp:2081)
==14909== by 0x5C9B87: pyston::IRGeneratorImpl::run(pyston::CFGBlock const*) (irgenerator.cpp:2442)
==14909== by 0x59550D: pyston::emitBBs(pyston::IRGenState*, char const*, pyston::GuardList&, pyston::GuardList const&, pyston::TypeAnalysis*, pyston::OSREntryDescriptor const*, std::unordered_set, std::equal_to, std::allocator > const&, std::unordered_set, std::equal_to, std::allocator > const&) (irgen.cpp:717)
==14909== by 0x58FDEB: pyston::doCompile(pyston::SourceInfo*, pyston::OSREntryDescriptor const*, pyston::EffortLevel::EffortLevel, pyston::FunctionSpecialization*, std::string) (irgen.cpp:1085)
==14909== by 0x5C5A16: pyston::compileFunction(pyston::CLFunction*, pyston::FunctionSpecialization*, pyston::EffortLevel::EffortLevel, pyston::OSREntryDescriptor const*) (hooks.cpp:194)
==14909== by 0x5C722E: pyston::compileAndRunModule(pyston::AST_Module*, pyston::BoxedModule*) (hooks.cpp:263)
==14909== by 0x672C88: main (jit.cpp:252)
==14909== Uninitialised value was created by a heap allocation
==14909== at 0x4C2B0C5: operator new(unsigned long) (vg_replace_malloc.c:324)
==14909== by 0x672B46: main (jit.cpp:236)
==14909==
True