News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Segment-Translation Exception

Started by Tracey.D, December 29, 2011, 07:36:34 PM

Previous topic - Next topic

Tracey.D

I'm trying to pull a number from an array that I've created and I'm getting a Segment-Translation Exception.  Any suggestions on what I should be looking at?

Thanks,
Tracey

bomz

May be a reason my poor English, but it's look like you need to get more detail information

Tracey.D

Essentially I'm trying to find the 95th and 75th percentile of an array of packed numbers.  I've created the array, calculated the spot to pull the 95th and 75th percentile from the array.  When I pull that data: 

UNPK    NINTY,0(8,R11)

I'm getting the Segment_Translation Exception.  R11 should contain the address for the 95th percentile member.

Hope this helps.  Please let me know if I can provide anything else.

Thanks,
Tracey

donkey

Not even sure what language this is:

UNPK NINTY,0(8,R11)

Sincce you are using R11, (an x86-64 register) I can't see much in the way of segment errors since they are pretty much bannished in 64 bit code. The only 2 segment registers that are still used in 64 bit mode (long mode) are the FS and GS registers and for a simple array it isn't likely that you would be using those (it would probably cause a rather spectacular crash of Windows anyway). Otherwise you are not using assembly language which would be a bit strange in an assembly language forum.

Working from the assumption that you realize this is an assembly language forum. From what you have said it sounds like you are getting a vector 11 interupt. That is normally seen as a segment not present exception in protected mode (present bit is 0 in the descriptor) however it can be triggered by a memory misalignment if the AC flag is set. It can also be the result of a stack overrun, that is if the SS segment register is loaded with a descriptor that is not valid, that will generate a vector 12 interupt but is also segment related (barely).

However, the error message you are quoting is not in the standard set of messages and you have not given any information at all about the OS (DOS or Windows) or even whether you are in Real/Kernel or Protected mode.
"Ahhh, what an awful dream. Ones and zeroes everywhere...[shudder] and I thought I saw a two." -- Bender
"It was just a dream, Bender. There's no such thing as two". -- Fry
-- Futurama

Donkey's Stable

Tracey.D

I'm working in the Mainframe environment.  I know this forum is primarily for windows based assembler, but was hoping someone could help me...

Thanks!
Tracey

donkey

Ah, that explains how you got that error code. I have no experience in main frame code however, the essentials should be the same. It would appear that the address you have generated during a read or write is outside of the allowable segments descriptors usually because you have exceeded the available memory in the segment. Are you running in an IBM mainframe environment ?
"Ahhh, what an awful dream. Ones and zeroes everywhere...[shudder] and I thought I saw a two." -- Bender
"It was just a dream, Bender. There's no such thing as two". -- Fry
-- Futurama

Donkey's Stable

Tracey.D

Thanks for your help!  The explanation you gave helped me figure it out....  I was shifting the wrong direction!  What a difference that made!!

Thank you again!!
Tracey  :cheekygreen: