[lkml]   [2015]   [Apr]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [V6,1/9] elf: Add new powerpc specifc core note sections
Anshuman Khandual <> wrote on 21.04.2015

> Changed ELF core note sections
> ------------------------------
> These core note sections need to be changed to accommodate the in
> transaction ptrace requests when the running/current value of these
> registers will reside some where else instead of the original places
> of thread_struct.
> /* Running register state */
> (1) NT_PRFPREG (Accessible always)
> (2) NT_PPC_VMX (Accessible always)
> (3) NT_PPC_VSX (Accessible always)
> New ELF core note sections
> --------------------------
> /* TM check pointed register set */
> (1) NT_PPC_TM_CGPR --> NT_PRSTATUS (Accessible inside TM)
> (2) NT_PPC_TM_CFPR --> NT_PRFPREG (Accessible inside TM)
> (3) NT_PPC_TM_CVMX --> NT_PPC_VMX (Accessible inside TM)
> (4) NT_PPC_TM_CVSX --> NT_PPC_VSX (Accessible inside TM)
> NOTE: The register set data structure for these ELF core not
> sections would exactly match with that of the corresponding
> running value register sets indicated above.


> /* TM SPR set */ (Accessible always)
> (5) NT_PPC_TM_SPR thread->tm_tfhar
> thread->tm_tfiar
> thread->ttm_exasr


> /* TM check pointed misc register set */
> (6) NT_PPC_TM_TAR thread->tm_tar (Accessible inside TM)
> (7) NT_PPC_TM_PPR thread->tm_ppr (Accessible inside TM)
> (8) NT_PPC_TM_DSCR thread->tm_dscr (Accessible inside TM)
> NOTE: Application can have a different set of TAR, PPR and DSCR
> registers inside the transaction compared that of the outside.
> Also seems like they are *not* the check pointed ones, will
> double check on this. Changed the core note section name from
> NT_PPC_TM_CTAR to just NT_PPC_TM_TAR and for all the others.

Huh? How is this not the checkpointed set? I would have
expected that NT_PPC_TAR contains the current tar (which is
the one in the transaction if we're within one), while
NT_PPC_TM_CTAR contains the checkpointed value that will be
restored once the transaction aborts. Why is this not the

> NOTE: They are like any other special purpose register which can
> be changed from the user space. So the elf core note section name
> can be generic. Here are some optional ELF core note sections
> which we can also add like the above ones.
> (12) NT_PPC_EBBRR thread->ebbrr (Accessible inside EBB)
> (13) NT_PPC_EBBHR thread->ebbhr (Accessible inside EBB)
> (14) NT_PPC_BESCR thread->bescr (Accessible inside EBB)
> (15) NT_PPC_SIAR thread->siar (Accessible inside EBB)
> (16) NT_PPC_SDAR thread->sdar (Accessible inside EBB)
> (17) NT_PPC_SIER thread->sier (Accessible inside EBB)
> (18) NT_PPC_MMCR2 thread->mmcr2 (Accessible inside EBB)
> (19) NT_PPC_MMCR0 thread->mmcr0 (Accessible inside EBB)

So I'm not really familiar with the EBB stuff. But just as a
general note, if those are in fact related (i.e. on every machine
that has EBB, all those registers will be available), it might
indeed make more sense to collect them into a single note section
(NT_PPC_EBB?) after all.


 \ /
  Last update: 2015-04-21 17:01    [W:0.099 / U:2.308 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site