[llvm] r246500 - WebAssembly: generate load/store

Dan Gohman via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 23 10:03:39 PDT 2015


On Wed, Sep 23, 2015 at 8:45 AM, Alexander Kornienko via llvm-commits <
llvm-commits at lists.llvm.org> wrote:

>
>
> On Tue, Sep 1, 2015 at 12:24 AM, JF Bastien via llvm-commits <
> llvm-commits at lists.llvm.org> wrote:
>
>> Author: jfb
>> Date: Mon Aug 31 17:24:11 2015
>> New Revision: 246500
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=246500&view=rev
>> Log:
>> WebAssembly: generate load/store
>>
>> Summary: This handles all load/store operations that WebAssembly defines,
>> and handles those necessary for C++ such as i1. I left a FIXME for
>> outstanding features which aren't required for now.
>>
>> Reviewers: sunfish
>>
>> Subscribers: jfb, llvm-commits, dschuff
>>
>> Added:
>>     llvm/trunk/test/CodeGen/WebAssembly/load-ext.ll
>>     llvm/trunk/test/CodeGen/WebAssembly/load-store-i1.ll
>>     llvm/trunk/test/CodeGen/WebAssembly/load.ll
>>     llvm/trunk/test/CodeGen/WebAssembly/store-trunc.ll
>>     llvm/trunk/test/CodeGen/WebAssembly/store.ll
>> Modified:
>>     llvm/trunk/lib/Target/WebAssembly/WebAssemblyAsmPrinter.cpp
>>     llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
>>     llvm/trunk/lib/Target/WebAssembly/WebAssemblyInstrMemory.td
>>
>> Modified: llvm/trunk/lib/Target/WebAssembly/WebAssemblyAsmPrinter.cpp
>> URL:
>> http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/WebAssembly/WebAssemblyAsmPrinter.cpp?rev=246500&r1=246499&r2=246500&view=diff
>>
>> ==============================================================================
>> --- llvm/trunk/lib/Target/WebAssembly/WebAssemblyAsmPrinter.cpp (original)
>> +++ llvm/trunk/lib/Target/WebAssembly/WebAssemblyAsmPrinter.cpp Mon Aug
>> 31 17:24:11 2015
>> @@ -40,6 +40,7 @@ using namespace llvm;
>>  namespace {
>>
>>  class WebAssemblyAsmPrinter final : public AsmPrinter {
>> +  bool hasAddr64;
>>
>
> This variable can be read without being initialized (fixed in r248388, but
> you probably need to look at why is it read before being initialized, what
> the right initial value is, etc.).
>

It was being read before being initialized because it was expected to be
initialized in runOnMachineFunction, but runOnMachineFunction wasn't
getting called since this testcase has no functions. This is now fixed in
r248394.


>
> Also, LLVM naming convention is to start data member names with a capital
> character.
>

r248394 also fixes this.

Thanks!

Dan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150923/f9210998/attachment.html>


More information about the llvm-commits mailing list