More on MIPS programs. SPIM does not support everything supported by a general MIPS assembler. For example, .end <function_name> doesn’t work Use j $ra
PowerPoint Slideshow about ' More on MIPS programs' - reeves
An Image/Link below is provided (as is) to download presentation
Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.
JVM code: ; x = 5; SIPUSH 5 ; get 5 ISTORE &x ; store at address of x ; y = x - 1 ILOAD &x ; load x onto stack for y=x-1 SIPUSH 1 ; 1 for y=x-1 ISUB ; subtract 1 from x ISTORE &y ; save the result in y ; if (x < y) goto label; ILOAD &x ; reload x ILOAD &y ; reload y ISUB ; subtract y from x IFLT label ; jump to label if top of stack contains something less than zero