| 
    
      
  | 
  
 Chromium Code Reviews
        
  Description[wasm]implement simd lowering for F32x4 and I32x4 binops
BUG=v8:4124
R=bradnelson@chromium.org,bbudge@chromium.org,gdeepti@chromium.org
Review-Url: https://codereview.chromium.org/2713613005
Cr-Commit-Position: refs/heads/master@{#43465}
Committed: https://chromium.googlesource.com/v8/v8/+/7f5701507d96c1eddd2ba6e3a86ef1f382a5b4f8
   
  Patch Set 1 #Patch Set 2 : fix min/max test #Patch Set 3 : [wasm]implement simd lowering for F32x4 and I32x4 binops #
      Total comments: 2
      
     
  
  Patch Set 4 : use namespace #
      Total comments: 6
      
     
  
  Patch Set 5 : comments #Patch Set 6 : fix float args for win build #Patch Set 7 : rebase #
      Total comments: 2
      
     
  
  Patch Set 8 : [wasm]implement simd lowering for F32x4 and I32x4 binops #Patch Set 9 : [wasm]implement simd lowering for F32x4 and I32x4 binops #Patch Set 10 : rebase #
 Depends on Patchset: Messages
    Total messages: 58 (40 generated)
     
  
  
 Description was changed from ========== [wasm]implement simd lowering for F32x4 and I32x4 binops BUG=v8:4124 R=bradnelson@chromium.org,bbudge@chromium.org,gdeepti@chromium.org ========== to ========== [wasm]implement simd lowering for F32x4 and I32x4 binops BUG=v8:4124 R=bradnelson@chromium.org,bbudge@chromium.org,gdeepti@chromium.org ========== 
 aseemgarg@chromium.org changed reviewers: + titzer@chromium.org 
 I32x4 Min and max functions are yet to be implemented. F32x4 min and max are not working. Any ideas? I printed the case where the test failed and it printed the values as -0 and 0 
 The CQ bit was checked by aseemgarg@chromium.org to run a CQ dry run 
 Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or... 
 The CQ bit was unchecked by commit-bot@chromium.org 
 Dry run: Try jobs failed on following builders: v8_win_compile_dbg on master.tryserver.v8 (JOB_FAILED, http://build.chromium.org/p/tryserver.v8/builders/v8_win_compile_dbg/builds/3...) v8_win_rel_ng on master.tryserver.v8 (JOB_FAILED, http://build.chromium.org/p/tryserver.v8/builders/v8_win_rel_ng/builds/23217) 
 On 2017/02/24 05:51:33, aseemgarg wrote: > I32x4 Min and max functions are yet to be implemented. > > F32x4 min and max are not working. Any ideas? > I printed the case where the test failed and it printed the values as -0 and 0 The float lane tests use an integer compare (after bit casting) so 0 and -0 will compare 
 On 2017/02/24 06:03:00, bbudge wrote: > On 2017/02/24 05:51:33, aseemgarg wrote: > > I32x4 Min and max functions are yet to be implemented. > > > > F32x4 min and max are not working. Any ideas? > > I printed the case where the test failed and it printed the values as -0 and 0 > > The float lane tests use an integer compare (after bit casting) so 0 and -0 will > compare not equal 
 The CQ bit was checked by aseemgarg@chromium.org to run a CQ dry run 
 Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or... 
 On 2017/02/24 06:03:16, bbudge wrote: > On 2017/02/24 06:03:00, bbudge wrote: > > On 2017/02/24 05:51:33, aseemgarg wrote: > > > I32x4 Min and max functions are yet to be implemented. > > > > > > F32x4 min and max are not working. Any ideas? > > > I printed the case where the test failed and it printed the values as -0 and > 0 > > > > The float lane tests use an integer compare (after bit casting) so 0 and -0 > will > > compare > > not equal Thanks. Fixed by not running compare for zero inputs. 
 The CQ bit was checked by aseemgarg@chromium.org to run a CQ dry run 
 Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or... 
 The CQ bit was unchecked by commit-bot@chromium.org 
 Dry run: This issue passed the CQ dry run. 
 aseemgarg@chromium.org changed reviewers: + mtrofin@chromium.org 
 https://codereview.chromium.org/2713613005/diff/40001/test/cctest/wasm/test-w... File test/cctest/wasm/test-wasm-simd-common.h (right): https://codereview.chromium.org/2713613005/diff/40001/test/cctest/wasm/test-w... test/cctest/wasm/test-wasm-simd-common.h:301: class TestWasmSimdCommon { Maybe use a namespace here instead of a class with only static methods as per the C++ styleguide? 
 https://codereview.chromium.org/2713613005/diff/40001/test/cctest/wasm/test-w... File test/cctest/wasm/test-wasm-simd-common.h (right): https://codereview.chromium.org/2713613005/diff/40001/test/cctest/wasm/test-w... test/cctest/wasm/test-wasm-simd-common.h:301: class TestWasmSimdCommon { On 2017/02/24 13:31:23, gdeepti wrote: > Maybe use a namespace here instead of a class with only static methods as per > the C++ styleguide? Done. 
 The CQ bit was checked by aseemgarg@chromium.org to run a CQ dry run 
 Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or... 
 The CQ bit was unchecked by commit-bot@chromium.org 
 Dry run: This issue passed the CQ dry run. 
 I like your idea of merging the tests. Why not go further, and put all tests into test-run-wasm-simd with appropriate #ifdef's so only the supported tests run? https://codereview.chromium.org/2713613005/diff/60001/src/compiler/simd-scala... File src/compiler/simd-scalar-lowering.cc (right): https://codereview.chromium.org/2713613005/diff/60001/src/compiler/simd-scala... src/compiler/simd-scalar-lowering.cc:83: V(Int32x4ReplaceLane) nit: Since we have many ops, I've been trying to order them, roughly: Create Extract/Replace lane Unary ops Binary ops Relational ops etc. And types ordered: Float32x4 Int32x4 Int16x8 Int8x16 Simd128 Simd32x4 Simd1x4 etc. https://codereview.chromium.org/2713613005/diff/60001/src/compiler/simd-scala... src/compiler/simd-scalar-lowering.cc:390: #define I32X4_BINOP_CASE(s_op, m_op) \ Macro param names: Name, instruction or op. https://codereview.chromium.org/2713613005/diff/60001/test/cctest/wasm/test-w... File test/cctest/wasm/test-wasm-simd-common.h (right): https://codereview.chromium.org/2713613005/diff/60001/test/cctest/wasm/test-w... test/cctest/wasm/test-wasm-simd-common.h:286: Could you also move the SIMD macros from wasm-macro-gen.h here as part of this CL? 
 Got rid of test-run-wasm-simd-lowering.cc and merged into test-run-wasm-simd. We don't need common anymore either https://codereview.chromium.org/2713613005/diff/60001/src/compiler/simd-scala... File src/compiler/simd-scalar-lowering.cc (right): https://codereview.chromium.org/2713613005/diff/60001/src/compiler/simd-scala... src/compiler/simd-scalar-lowering.cc:83: V(Int32x4ReplaceLane) On 2017/02/24 20:53:35, bbudge wrote: > nit: Since we have many ops, I've been trying to order them, roughly: > Create > Extract/Replace lane > Unary ops > Binary ops > Relational ops > etc. > > And types ordered: > Float32x4 > Int32x4 > Int16x8 > Int8x16 > Simd128 > Simd32x4 > Simd1x4 etc. Done. https://codereview.chromium.org/2713613005/diff/60001/src/compiler/simd-scala... src/compiler/simd-scalar-lowering.cc:390: #define I32X4_BINOP_CASE(s_op, m_op) \ On 2017/02/24 20:53:36, bbudge wrote: > Macro param names: Name, instruction or op. changed to opcode, instruction https://codereview.chromium.org/2713613005/diff/60001/test/cctest/wasm/test-w... File test/cctest/wasm/test-wasm-simd-common.h (right): https://codereview.chromium.org/2713613005/diff/60001/test/cctest/wasm/test-w... test/cctest/wasm/test-wasm-simd-common.h:286: On 2017/02/24 20:53:36, bbudge wrote: > Could you also move the SIMD macros from wasm-macro-gen.h here as part of this > CL? Done. 
 The CQ bit was checked by aseemgarg@chromium.org to run a CQ dry run 
 Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or... 
 The CQ bit was unchecked by commit-bot@chromium.org 
 Dry run: Try jobs failed on following builders: v8_win_nosnap_shared_rel_ng on master.tryserver.v8 (JOB_FAILED, http://build.chromium.org/p/tryserver.v8/builders/v8_win_nosnap_shared_rel_ng...) 
 The CQ bit was checked by aseemgarg@chromium.org to run a CQ dry run 
 Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or... 
 The CQ bit was unchecked by commit-bot@chromium.org 
 Dry run: This issue passed the CQ dry run. 
 The CQ bit was checked by aseemgarg@chromium.org to run a CQ dry run 
 Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or... 
 The CQ bit was unchecked by commit-bot@chromium.org 
 Dry run: This issue passed the CQ dry run. 
 Nice, LGTM with 1 comment. https://codereview.chromium.org/2713613005/diff/120001/test/cctest/wasm/test-... File test/cctest/wasm/test-run-wasm-simd.cc (right): https://codereview.chromium.org/2713613005/diff/120001/test/cctest/wasm/test-... test/cctest/wasm/test-run-wasm-simd.cc:231: x, kSimdPrefix, static_cast<byte>(kExprF32x4Splat) These can be defined as WASM_SIMD_UNOP( op, x) if you move them down with the other splat/extract/replace macros. 
 https://codereview.chromium.org/2713613005/diff/120001/test/cctest/wasm/test-... File test/cctest/wasm/test-run-wasm-simd.cc (right): https://codereview.chromium.org/2713613005/diff/120001/test/cctest/wasm/test-... test/cctest/wasm/test-run-wasm-simd.cc:231: x, kSimdPrefix, static_cast<byte>(kExprF32x4Splat) On 2017/02/27 18:26:15, bbudge wrote: > These can be defined as WASM_SIMD_UNOP( op, x) if you move them down with the > other splat/extract/replace macros. Got rid of add macros and moved down others. 
 The CQ bit was checked by aseemgarg@chromium.org 
 The patchset sent to the CQ was uploaded after l-g-t-m from bbudge@chromium.org Link to the patchset: https://codereview.chromium.org/2713613005/#ps140001 (title: "[wasm]implement simd lowering for F32x4 and I32x4 binops") 
 CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or... 
 The CQ bit was unchecked by commit-bot@chromium.org 
 Try jobs failed on following builders: v8_presubmit on master.tryserver.v8 (JOB_FAILED, http://build.chromium.org/p/tryserver.v8/builders/v8_presubmit/builds/35627) 
 The CQ bit was checked by aseemgarg@chromium.org to run a CQ dry run 
 Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or... 
 On 2017/02/27 22:13:19, commit-bot: I haz the power wrote: > Try jobs failed on following builders: > v8_presubmit on master.tryserver.v8 (JOB_FAILED, > http://build.chromium.org/p/tryserver.v8/builders/v8_presubmit/builds/35627) Rubber stamp lgtm 
 The CQ bit was unchecked by commit-bot@chromium.org 
 Dry run: Try jobs failed on following builders: v8_linux_rel_ng on master.tryserver.v8 (JOB_FAILED, http://build.chromium.org/p/tryserver.v8/builders/v8_linux_rel_ng/builds/21637) v8_linux_rel_ng_triggered on master.tryserver.v8 (JOB_FAILED, http://build.chromium.org/p/tryserver.v8/builders/v8_linux_rel_ng_triggered/b...) 
 The CQ bit was checked by aseemgarg@chromium.org 
 The patchset sent to the CQ was uploaded after l-g-t-m from bbudge@chromium.org, mtrofin@chromium.org Link to the patchset: https://codereview.chromium.org/2713613005/#ps180001 (title: "rebase") 
 CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or... 
 CQ is committing da patch.
Bot data: {"patchset_id": 180001, "attempt_start_ts": 1488237321014910,
"parent_rev": "ef2a9e2debc8b8888348a4231d155e7ddcc86bda", "commit_rev":
"7f5701507d96c1eddd2ba6e3a86ef1f382a5b4f8"}
          
 
            
              
                Message was sent while issue was closed.
              
            
             
          
        Description was changed from ========== [wasm]implement simd lowering for F32x4 and I32x4 binops BUG=v8:4124 R=bradnelson@chromium.org,bbudge@chromium.org,gdeepti@chromium.org ========== to ========== [wasm]implement simd lowering for F32x4 and I32x4 binops BUG=v8:4124 R=bradnelson@chromium.org,bbudge@chromium.org,gdeepti@chromium.org Review-Url: https://codereview.chromium.org/2713613005 Cr-Commit-Position: refs/heads/master@{#43465} Committed: https://chromium.googlesource.com/v8/v8/+/7f5701507d96c1eddd2ba6e3a86ef1f382a... ========== 
 
            
              
                Message was sent while issue was closed.
              
            
             
          
        Committed patchset #10 (id:180001) as https://chromium.googlesource.com/v8/v8/+/7f5701507d96c1eddd2ba6e3a86ef1f382a... 
 
            
              
                Message was sent while issue was closed.
              
            
             
          
        Note: This fails on arm chromebooks: https://build.chromium.org/p/client.v8.ports/builders/V8%20Arm/builds/2300 Please have a look. 
 
            
              
                Message was sent while issue was closed.
              
            
             
          
        On 2017/02/28 16:20:08, Michael Achenbach wrote: > Note: This fails on arm chromebooks: > https://build.chromium.org/p/client.v8.ports/builders/V8%20Arm/builds/2300 > > Please have a look. These are probably failing because ARM Neon arithmetic is slightly non-standard. For now, disable these tests in: test/cctest/cctest.status I'm working on a fix for our FP tests: https://codereview.chromium.org/2594043002/ 
 
            
              
                Message was sent while issue was closed.
              
            
             
          
        On 2017/02/28 16:20:08, Michael Achenbach wrote: > Note: This fails on arm chromebooks: > https://build.chromium.org/p/client.v8.ports/builders/V8%20Arm/builds/2300 > > Please have a look. This patch should fix it (disabled the failing tests for arm) https://codereview.chromium.org/2723823002/  | 
    |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
