Deleted Added
sdiff udiff text old ( 5295:5268691561b4 ) new ( 5433:1b0b8e9ba6a9 )
full compact
1# Copyright (c) 2007 The Hewlett-Packard Development Company
2# All rights reserved.
3#
4# Redistribution and use of this software in source and binary forms,
5# with or without modification, are permitted provided that the
6# following conditions are met:
7#
8# The software must be used only for Non-Commercial Use which means any
9# use which is NOT directed to receiving any direct monetary

--- 70 unchanged lines hidden (view full) ---

80
81def macroop RET_FAR {
82 .adjust_env oszIn64Override
83
84 # Get the return RIP
85 ld t1, ss, [1, t0, rsp]
86
87 # Get the return CS
88 ld t2, ss, [1, t0, rsp], dsz
89
90 # Get the rpl
91 andi t3, t2, 0x3
92
93 # Get the cpl
94
95 # Here we'd check if we're changing priviledge levels. We'll just hope
96 # that doesn't happen yet.
97
98 # Do stuff if they're equal
99 chks t4, t2, flags=(EZF,)
100 fault "new GeneralProtection(0)", flags=(CEZF,)
101 ld t3, flatseg, [1, t0, t4], addressSize=8, dataSize=8
102 wrdl cs, t3, t2
103 # There should be validity checks on the RIP checks here, but I'll do
104 # that later.
105 wrip t0, t1
106 bri t0, label("end")
107
108 # Do other stuff if they're not.
109end:
110 fault "NoFault"
111};
112'''