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

Issue 11308039: MIPS: Fix NaClSwitch() to set $t9 to the address of the entry point (Closed)

Created:
8 years, 1 month ago by Mark Seaborn
Modified:
8 years, 1 month ago
Reviewers:
petarj
CC:
native-client-reviews_googlegroups.com
Visibility:
Public.

Description

MIPS: Fix NaClSwitch() to set $t9 to the address of the entry point The MIPS calling convention is that a function is called with $t9 set to the address of the function being called. This is used rather like %ebx on x86-32 for locating global variables. This change is needed to make hello_world.nexe work, otherwise the nexe crashes the first time it dereferences a pointer derived from $t9. This also fixes an information leak: we no longer leak the value of $t9 from trusted code. BUG=https://code.google.com/p/nativeclient/issues/detail?id=2275 TEST=hello_world (with other changes applied locally) Committed: https://src.chromium.org/viewvc/native_client?view=rev&revision=10278

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+14 lines, -9 lines) Patch
M src/trusted/service_runtime/arch/mips/nacl_switch.S View 2 chunks +14 lines, -9 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
Mark Seaborn
I got hello_world to run. I'll send you more details in other posts. Did you ...
8 years, 1 month ago (2012-11-15 16:05:53 UTC) #1
petarj
On 2012/11/15 16:05:53, Mark Seaborn wrote: > I got hello_world to run. I'll send you ...
8 years, 1 month ago (2012-11-15 16:50:56 UTC) #2
Mark Seaborn
On 15 November 2012 08:50, <petarj@mips.com> wrote: > On 2012/11/15 16:05:53, Mark Seaborn wrote: > ...
8 years, 1 month ago (2012-11-15 16:55:24 UTC) #3
petarj
8 years, 1 month ago (2012-11-15 17:01:42 UTC) #4
lgtm

Powered by Google App Engine
This is Rietveld 408576698