Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(234)

Unified Diff: src/asmjs/asm-wasm-builder.cc

Issue 2200213002: asm.js. Adds support for clz32 in asm.js. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: addresses comment Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/asmjs/asm-typer.cc ('k') | test/mjsunit/wasm/asm-wasm-stdlib.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/asmjs/asm-wasm-builder.cc
diff --git a/src/asmjs/asm-wasm-builder.cc b/src/asmjs/asm-wasm-builder.cc
index 9ac748bdd0f4b553327ecbe0c32855372b45cc68..644edc47b6e671f480301ebdb80d5306d5e85a6b 100644
--- a/src/asmjs/asm-wasm-builder.cc
+++ b/src/asmjs/asm-wasm-builder.cc
@@ -1085,6 +1085,12 @@ class AsmWasmBuilderImpl final : public AstVisitor<AsmWasmBuilderImpl> {
}
break;
}
+ case AsmTyper::kMathClz32: {
+ VisitCallArgs(call);
+ DCHECK(call_type == kAstI32);
+ current_function_builder_->Emit(kExprI32Clz);
+ break;
+ }
case AsmTyper::kMathAbs: {
if (call_type == kAstI32) {
uint32_t tmp = current_function_builder_->AddLocal(kAstI32);
« no previous file with comments | « src/asmjs/asm-typer.cc ('k') | test/mjsunit/wasm/asm-wasm-stdlib.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698