[Liftoff][cleanup] Fix comment and use register constant

The comment in {CallRuntime} was misleading. The {rsi}/{esi} register
did not hold the instance, but the context instead. The generated code
was correct thought.

R=titzer@chromium.org

Change-Id: I18020a04ac75faedf7ad5e4b07cab27ae0aedae7
Reviewed-on: https://chromium-review.googlesource.com/1051232
Reviewed-by: Ben Titzer <titzer@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53088}
This commit is contained in:
Clemens Hammacher 2018-05-09 09:15:30 +02:00 committed by Commit Bot
parent 600641338d
commit b50ac57d12
2 changed files with 4 additions and 4 deletions

View File

@ -1557,8 +1557,8 @@ void LiftoffAssembler::CallNativeWasmCode(Address addr) {
}
void LiftoffAssembler::CallRuntime(Zone* zone, Runtime::FunctionId fid) {
// Set instance to zero.
xor_(esi, esi);
// Set context to zero (Smi::kZero) for the runtime call.
xor_(kContextRegister, kContextRegister);
CallRuntimeDelayed(zone, fid);
}

View File

@ -1410,8 +1410,8 @@ void LiftoffAssembler::CallNativeWasmCode(Address addr) {
}
void LiftoffAssembler::CallRuntime(Zone* zone, Runtime::FunctionId fid) {
// Set instance to zero.
xorp(rsi, rsi);
// Set context to zero (Smi::kZero) for the runtime call.
xorp(kContextRegister, kContextRegister);
CallRuntimeDelayed(zone, fid);
}