Bug 152186

Summary: B3::reduceStrength should simplify Div(value, 1 << const)
Product: WebKit Reporter: Filip Pizlo <fpizlo>
Component: JavaScriptCoreAssignee: Robin Morisset <rmorisset>
Status: ASSIGNED    
Severity: Normal CC: ahmad.saleem792, ews-watchlist, keith_miller, mark.lam, msaboff, rmorisset, saam
Priority: P2    
Version: WebKit Nightly Build   
Hardware: All   
OS: All   
See Also: https://bugs.webkit.org/show_bug.cgi?id=196370
Bug Depends on:    
Bug Blocks: 154319, 196361    
Attachments:
Description Flags
Patch rmorisset: review-, ews-watchlist: commit-queue-

Filip Pizlo
Reported 2015-12-11 13:34:17 PST
asm.js needs this.
Attachments
Patch (12.00 KB, patch)
2019-03-28 14:47 PDT, Robin Morisset
rmorisset: review-
ews-watchlist: commit-queue-
Robin Morisset
Comment 1 2019-03-28 14:47:05 PDT
EWS Watchlist
Comment 2 2019-03-28 17:28:54 PDT
Comment on attachment 366211 [details] Patch Attachment 366211 [details] did not pass jsc-ews (mac): Output: https://webkit-queues.webkit.org/results/11695667 New failing tests: microbenchmarks/integer-modulo.js.ftl-eager jsc-layout-tests.yaml/js/script-tests/integer-division-neg2tothe32-by-neg1.js.layout-ftl-eager-no-cjit microbenchmarks/integer-modulo.js.ftl-eager-no-cjit microbenchmarks/integer-modulo.js.ftl-no-cjit-no-inline-validate microbenchmarks/integer-modulo.js.ftl-no-cjit-no-put-stack-validate stress/op_mod-VarConst.js.misc-ftl-no-cjit microbenchmarks/integer-modulo.js.ftl-no-cjit-validate-sampling-profiler
Robin Morisset
Comment 3 2019-03-29 16:07:48 PDT
I think I found the bug: I assumed that Div was rounding towards -Infinity, but it appears to round towards 0 (or x % y would not be equal to x - (x / y ) * y). I am not entirely sure how to fix it right now.
Ahmad Saleem
Comment 4 2024-06-22 13:51:50 PDT
Note You need to log in before you can comment on or make changes to this bug.