Changeset 74813216 in mainline for arch/sparc64/src


Ignore:
Timestamp:
2005-12-01T13:36:01Z (20 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
22e10ab
Parents:
ee69c49
Message:

sparc64 work.
No need to save/restore local registers.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • arch/sparc64/src/context.S

    ree69c49 r74813216  
    3636
    3737.macro CONTEXT_STORE r
    38         stx %l0, [\r + OFFSET_L0]
    39         stx %l1, [\r + OFFSET_L1]
    40         stx %l2, [\r + OFFSET_L2]
    41         stx %l3, [\r + OFFSET_L3]
    42         stx %l4, [\r + OFFSET_L4]
    43         stx %l5, [\r + OFFSET_L5]
    44         stx %l6, [\r + OFFSET_L6]
    45         stx %l7, [\r + OFFSET_L7]
    4638        stx %i1, [\r + OFFSET_I1]
    4739        stx %i2, [\r + OFFSET_I2]
     
    4941        stx %i4, [\r + OFFSET_I4]
    5042        stx %i5, [\r + OFFSET_I5]
    51         stx %i6, [\r + OFFSET_SP]
     43        stx %fp, [\r + OFFSET_FP]
    5244        stx %i7, [\r + OFFSET_PC]
     45        stx %sp, [\r + OFFSET_SP]
    5346.endm
    5447
    5548.macro CONTEXT_LOAD r
    56         ldx [\r + OFFSET_L0], %l0
    57         ldx [\r + OFFSET_L1], %l1
    58         ldx [\r + OFFSET_L2], %l2
    59         ldx [\r + OFFSET_L3], %l3
    60         ldx [\r + OFFSET_L4], %l4
    61         ldx [\r + OFFSET_L5], %l5
    62         ldx [\r + OFFSET_L6], %l6
    63         ldx [\r + OFFSET_L7], %l7
    6449        ldx [\r + OFFSET_I1], %i1
    6550        ldx [\r + OFFSET_I2], %i2
     
    6752        ldx [\r + OFFSET_I4], %i4
    6853        ldx [\r + OFFSET_I5], %i5
    69         ldx [\r + OFFSET_SP], %i6
     54        ldx [\r + OFFSET_FP], %fp
    7055        ldx [\r + OFFSET_PC], %i7
    7156        ldx [\r + OFFSET_SP], %sp
     
    7863
    7964        # context_save returns 1
    80         mov 1, %i0     
     65        mov 1, %i0
    8166        ret
    82         restore %sp, 128, %sp
    83        
     67        restore %sp, STACK_WINDOW_SAVE_AREA_SIZE, %sp
     68
    8469context_restore_arch:
    8570        save %sp, -STACK_WINDOW_SAVE_AREA_SIZE, %sp
     
    8772
    8873        # context_restore returns 0
    89         xor %i0, %i0, %i0                       
     74        xor %i0, %i0, %i0
    9075        ret
    91         restore %sp, STACK_WINDOW_SAVE_AREA_SIZE, %sp   
     76        restore %sp, STACK_WINDOW_SAVE_AREA_SIZE, %sp
Note: See TracChangeset for help on using the changeset viewer.