This is the mail archive of the mailing list for the GDB project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ymm register error

On 2018-07-17 07:43, Paul Topley wrote:
When trying to run gdb server on a skylake-x HEDT platform (i9-7940X)
I encounter the following error:

regcache.c:264: A problem internal to GDBserver has been detected.
Unknown register ymm0h requested

From what I can tell from furious googling is that the ymm registers
have changed location from broadwell-e to skylake-x.

I can see references to the ymm registers in gdb's codebase, with
apparent positioning related to features like org.gnu.gdb.i386.avx &

Being a complete novice around gdb's codebase, I'm not sure if I need
to enable or state something at configure stage so that the right ymm
register location is referenced.

gdb server 8 in ubuntu bionics repos works OK on the skylake-x
platform, but when I compile myself it does not.

Is there something specific I need to be stating at compile time to
"get" gdbserver 8 to work on skylake-x


Hi Paul,

I don't have access to a system with this kind of processor, so I can only give you pointers on how I would debug this.

My first intuition would be to debug gdbserver, starting at the "x86_linux_read_description" function. There, gdbserver tries to detect what features are available on the current processor and create a corresponding target description (essentially the list of existing registers). It's possible that it's getting something wrong. This code has also changed in the last few releases, changing from static lists to something created more dynamically. Normally, execution would end up in amd64_create_target_description.

You processors supports the AVX instructions and therefore has the ymm0h register, so it should enter this condition:

  if (xcr0 & X86_XSTATE_AVX)
    regnum = create_feature_i386_64bit_avx (tdesc, regnum);

But it also has AVX-512, so it should probably also enter this condition:

  if (xcr0 & X86_XSTATE_AVX512)
    regnum = create_feature_i386_64bit_avx512 (tdesc, regnum);


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]