alexandreyy (Alexandre Yukio Yamashita)
User

Projects

User does not belong to any projects.

User Details

User Since
Aug 16 2017, 1:09 PM (14 w, 20 m)

Recent Activity

Today

alexandreyy accepted D39016: Add Percent Symbol In PPC Registers for Linux.

Thanks, @joerg !
It looks better than before.

Wed, Nov 22, 3:30 AM

Yesterday

alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

@joerg, @echristo, Could you check if these changes are Ok?
Thanks!

Tue, Nov 21, 3:58 AM

Thu, Nov 16

alexandreyy added a comment to D40133: elf-core: Convert remaining register context to use register set maps.

Looks good to me!

Thu, Nov 16, 10:29 AM
alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

@joerg, @echristo, Could you check if these changes are Ok?
Thanks!

Thu, Nov 16, 9:52 AM
alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

ping

Thu, Nov 16, 3:30 AM
alexandreyy added a comment to D39681: Implement core dump debugging for PPC64le.

Also, I have trouble downloading the core file from phabricator. Alexandre, can you sent them to me directly?

Thu, Nov 16, 3:29 AM
alexandreyy updated the diff for D39681: Implement core dump debugging for PPC64le.

Removed enums without namespaces.

Thu, Nov 16, 3:18 AM

Tue, Nov 14

alexandreyy added inline comments to D39681: Implement core dump debugging for PPC64le.
Tue, Nov 14, 12:13 PM
alexandreyy added inline comments to D39681: Implement core dump debugging for PPC64le.
Tue, Nov 14, 11:44 AM
alexandreyy updated the diff for D39681: Implement core dump debugging for PPC64le.

Removed issue note from commit message.

Tue, Nov 14, 10:58 AM
alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

Hi, guys!
Are these changes Ok to commit?

Tue, Nov 14, 10:49 AM
alexandreyy added a comment to D39681: Implement core dump debugging for PPC64le.

I'm not sure what's the problem with backtracing without more info, but the nice thing about core files is that you can open a ppc and x86 one side by side and see how for do you get before things start to diverge. The interesting commands you can start with are "image lookup" (to see if you can find symbols properly), "image show-unwind" (to see the unwind plans) and "log enable lldb unwind && bt" (to see backtracing in action). This is what I get for the x86_64 core file (you should be able to see the same thing yourself):

(lldb) bt
* thread #1, name = 'a.out', stop reason = signal SIGSEGV
  * frame #0: 0x000000000040011c linux-x86_64.out`bar(boom=0x0000000000000000) at main.c:4
    frame #1: 0x0000000000400142 linux-x86_64.out`foo(boom=0x0000000000000000, boomer=(linux-x86_64.out`bar at main.c:2)) at main.c:10
    frame #2: 0x000000000040015f linux-x86_64.out`_start at main.c:16
(lldb) image lookup -n bar
1 match found in /usr/local/google/home/labath/ll/lldb/test/testcases/functionalities/postmortem/elf-core/linux-x86_64.out:
        Address: linux-x86_64.out[0x000000000040010c] (linux-x86_64.out..text + 0)
        Summary: linux-x86_64.out`bar at main.c:2
(lldb) image show-unwind -n bar
UNWIND PLANS for linux-x86_64.out`bar (start addr 0x40010c)

Asynchronous (not restricted to call-sites) UnwindPlan is 'assembly insn profiling'
Synchronous (restricted to call-sites) UnwindPlan is 'eh_frame CFI'
Fast UnwindPlan is 'x86_64 default unwind plan'

Assembly language inspection UnwindPlan:
This UnwindPlan originally sourced from assembly insn profiling
This UnwindPlan is sourced from the compiler: no.
This UnwindPlan is valid at all instruction locations: yes.
Address range of this UnwindPlan: [linux-x86_64.out..text + 0-0x0000000000000015)
row[0]:    0: CFA=rsp +8 => rsp=CFA+0 rip=[CFA-8] 
row[1]:    1: CFA=rsp+16 => rbp=[CFA-16] rsp=CFA+0 rip=[CFA-8] 
row[2]:    4: CFA=rbp+16 => rbp=[CFA-16] rsp=CFA+0 rip=[CFA-8] 
row[3]:   20: CFA=rsp +8 => rsp=CFA+0 rip=[CFA-8] 

eh_frame UnwindPlan:
This UnwindPlan originally sourced from eh_frame CFI
This UnwindPlan is sourced from the compiler: yes.
This UnwindPlan is valid at all instruction locations: no.
Address range of this UnwindPlan: [linux-x86_64.out..text + 0-0x0000000000000015)
row[0]:    0: CFA=rsp +8 => rip=[CFA-8] 
row[1]:    1: CFA=rsp+16 => rbp=[CFA-16] rip=[CFA-8] 
row[2]:    4: CFA=rbp+16 => rbp=[CFA-16] rip=[CFA-8] 
row[3]:   20: CFA=rsp +8 => rbp=[CFA-16] rip=[CFA-8] 

Fast UnwindPlan:
This UnwindPlan originally sourced from x86_64 default unwind plan
This UnwindPlan is sourced from the compiler: no.
This UnwindPlan is valid at all instruction locations: no.
row[0]:    0: CFA=rbp+16 => rbp=[CFA-16] rsp=CFA+0 rip=[CFA-8] 

Arch default UnwindPlan:
This UnwindPlan originally sourced from x86_64 default unwind plan
This UnwindPlan is sourced from the compiler: no.
This UnwindPlan is valid at all instruction locations: no.
row[0]:    0: CFA=rbp+16 => rbp=[CFA-16] rsp=CFA+0 rip=[CFA-8] 

Arch default at entry point UnwindPlan:
This UnwindPlan originally sourced from x86_64 at-func-entry default
This UnwindPlan is sourced from the compiler: no.
This UnwindPlan is valid at all instruction locations: not specified.
row[0]:    0: CFA=rsp +8 => rsp=CFA+0 rip=[CFA-8]
Tue, Nov 14, 10:43 AM
alexandreyy updated the diff for D39681: Implement core dump debugging for PPC64le.

Fixed backtrace issue.

Tue, Nov 14, 10:38 AM

Fri, Nov 10

alexandreyy added inline comments to D39016: Add Percent Symbol In PPC Registers for Linux.
Fri, Nov 10, 11:15 AM
alexandreyy updated the diff for D39016: Add Percent Symbol In PPC Registers for Linux.

Fixed identation.

Fri, Nov 10, 11:06 AM
alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

I really appreciate you doing this work. This has been something I've wanted for some time :)

I've added a few things to this. Should also have a testcase as well.

Thanks!

-eric

Thanks @echristo.
I modified the patch according to your comments.

Fri, Nov 10, 10:58 AM
alexandreyy updated the diff for D39016: Add Percent Symbol In PPC Registers for Linux.

Updated patch according to review.

Fri, Nov 10, 10:56 AM
alexandreyy added a comment to D39681: Implement core dump debugging for PPC64le.

Looks good, thank you. Just please make sure you change the file name at top of the new header file and add inclusion guards.

Fri, Nov 10, 5:10 AM
alexandreyy updated the diff for D39681: Implement core dump debugging for PPC64le.

Added inclusion guards in elf-core-enums.h

Fri, Nov 10, 5:05 AM

Thu, Nov 9

alexandreyy updated the diff for D39681: Implement core dump debugging for PPC64le.

Fixed test identation

Thu, Nov 9, 11:00 AM
alexandreyy updated the diff for D39681: Implement core dump debugging for PPC64le.

Changed namespaces in core enums.

Thu, Nov 9, 10:13 AM
alexandreyy added a comment to D39681: Implement core dump debugging for PPC64le.

I'm not sure what's the problem with backtracing without more info, but the nice thing about core files is that you can open a ppc and x86 one side by side and see how for do you get before things start to diverge. The interesting commands you can start with are "image lookup" (to see if you can find symbols properly), "image show-unwind" (to see the unwind plans) and "log enable lldb unwind && bt" (to see backtracing in action). This is what I get for the x86_64 core file (you should be able to see the same thing yourself):

(lldb) bt
* thread #1, name = 'a.out', stop reason = signal SIGSEGV
  * frame #0: 0x000000000040011c linux-x86_64.out`bar(boom=0x0000000000000000) at main.c:4
    frame #1: 0x0000000000400142 linux-x86_64.out`foo(boom=0x0000000000000000, boomer=(linux-x86_64.out`bar at main.c:2)) at main.c:10
    frame #2: 0x000000000040015f linux-x86_64.out`_start at main.c:16
(lldb) image lookup -n bar
1 match found in /usr/local/google/home/labath/ll/lldb/test/testcases/functionalities/postmortem/elf-core/linux-x86_64.out:
        Address: linux-x86_64.out[0x000000000040010c] (linux-x86_64.out..text + 0)
        Summary: linux-x86_64.out`bar at main.c:2
(lldb) image show-unwind -n bar
UNWIND PLANS for linux-x86_64.out`bar (start addr 0x40010c)

Asynchronous (not restricted to call-sites) UnwindPlan is 'assembly insn profiling'
Synchronous (restricted to call-sites) UnwindPlan is 'eh_frame CFI'
Fast UnwindPlan is 'x86_64 default unwind plan'

Assembly language inspection UnwindPlan:
This UnwindPlan originally sourced from assembly insn profiling
This UnwindPlan is sourced from the compiler: no.
This UnwindPlan is valid at all instruction locations: yes.
Address range of this UnwindPlan: [linux-x86_64.out..text + 0-0x0000000000000015)
row[0]:    0: CFA=rsp +8 => rsp=CFA+0 rip=[CFA-8] 
row[1]:    1: CFA=rsp+16 => rbp=[CFA-16] rsp=CFA+0 rip=[CFA-8] 
row[2]:    4: CFA=rbp+16 => rbp=[CFA-16] rsp=CFA+0 rip=[CFA-8] 
row[3]:   20: CFA=rsp +8 => rsp=CFA+0 rip=[CFA-8] 

eh_frame UnwindPlan:
This UnwindPlan originally sourced from eh_frame CFI
This UnwindPlan is sourced from the compiler: yes.
This UnwindPlan is valid at all instruction locations: no.
Address range of this UnwindPlan: [linux-x86_64.out..text + 0-0x0000000000000015)
row[0]:    0: CFA=rsp +8 => rip=[CFA-8] 
row[1]:    1: CFA=rsp+16 => rbp=[CFA-16] rip=[CFA-8] 
row[2]:    4: CFA=rbp+16 => rbp=[CFA-16] rip=[CFA-8] 
row[3]:   20: CFA=rsp +8 => rbp=[CFA-16] rip=[CFA-8] 

Fast UnwindPlan:
This UnwindPlan originally sourced from x86_64 default unwind plan
This UnwindPlan is sourced from the compiler: no.
This UnwindPlan is valid at all instruction locations: no.
row[0]:    0: CFA=rbp+16 => rbp=[CFA-16] rsp=CFA+0 rip=[CFA-8] 

Arch default UnwindPlan:
This UnwindPlan originally sourced from x86_64 default unwind plan
This UnwindPlan is sourced from the compiler: no.
This UnwindPlan is valid at all instruction locations: no.
row[0]:    0: CFA=rbp+16 => rbp=[CFA-16] rsp=CFA+0 rip=[CFA-8] 

Arch default at entry point UnwindPlan:
This UnwindPlan originally sourced from x86_64 at-func-entry default
This UnwindPlan is sourced from the compiler: no.
This UnwindPlan is valid at all instruction locations: not specified.
row[0]:    0: CFA=rsp +8 => rsp=CFA+0 rip=[CFA-8]
Thu, Nov 9, 6:52 AM
alexandreyy updated the diff for D39681: Implement core dump debugging for PPC64le.

Moved core enums to header file.

Thu, Nov 9, 6:49 AM
alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

Hi,
Could someone review/approve this patch, please?
I don't have the permissions to commit it.
Thanks. ;)

Thu, Nov 9, 4:32 AM
alexandreyy added a comment to D39681: Implement core dump debugging for PPC64le.

Thanks for all the reviews @labath and @clayborg.
I changed the code to use the DenseMap and added the files for testing.
The backtrace is not working properly yet,
It is showing all frames, just the current.
Am I missing something?

Thu, Nov 9, 4:26 AM
alexandreyy updated the diff for D39681: Implement core dump debugging for PPC64le.

Update according to reviews.

Thu, Nov 9, 4:19 AM

Mon, Nov 6

alexandreyy created D39681: Implement core dump debugging for PPC64le.
Mon, Nov 6, 4:40 AM

Fri, Nov 3

alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

Hi, @joerg
Could you review/approve these changes?

Fri, Nov 3, 8:01 AM
alexandreyy added a comment to D39487: Add float/vector registers for ppc64le.

Thanks @labath.
I adjusted the VSX and VMX methods.

Fri, Nov 3, 7:58 AM
alexandreyy updated the diff for D39487: Add float/vector registers for ppc64le.

Simplified vector register methods

Fri, Nov 3, 7:54 AM

Wed, Nov 1

alexandreyy added a comment to D39487: Add float/vector registers for ppc64le.

@clayborg Thanks for the review.

Wed, Nov 1, 11:00 AM
alexandreyy updated subscribers of D39487: Add float/vector registers for ppc64le.
Wed, Nov 1, 10:56 AM
alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

Are these changes ok?

Wed, Nov 1, 6:04 AM
alexandreyy created D39487: Add float/vector registers for ppc64le.
Wed, Nov 1, 5:15 AM

Mon, Oct 30

alexandreyy updated the diff for D39016: Add Percent Symbol In PPC Registers for Linux.

Update patch according to suggestions

Mon, Oct 30, 8:18 AM

Fri, Oct 27

alexandreyy added inline comments to D39016: Add Percent Symbol In PPC Registers for Linux.
Fri, Oct 27, 12:18 PM
alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

Hi.
Are these changes ok?

Fri, Oct 27, 7:54 AM

Tue, Oct 24

alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

If what we want is to name the registers with the percent sign prefix on all non-AIX, non-Darwin systems, why not just change the definitions in the .td files to include the prefix? That way you don't have to worry about this kind of hacky/leaky code to prepend the symbol to the register names. And on AIX/Darwin, we just strip the full prefix (percent symbol and letter). Considering that it is questionable whether LLVM will ever have full support on AIX and that Darwin support is likely to be pulled soon, this seems like the best choice.

Of course, we'd then need to decide how we want to print the CR registers (i.e. if we want to have the ability to print them the way binutils tools print them - 4*cr4+gt, etc.)

Tue, Oct 24, 9:45 AM
alexandreyy updated the diff for D39016: Add Percent Symbol In PPC Registers for Linux.

Changed printRegisterWithPercentPrefix to showRegistersWithPercentPrefix

Tue, Oct 24, 9:30 AM
alexandreyy updated the diff for D39016: Add Percent Symbol In PPC Registers for Linux.

Update according to review comments

Tue, Oct 24, 6:21 AM

Oct 23 2017

alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

Because it is not possible to change the cl option by LLDB.

There should be no need to. This is not a public interface anyway. Long term, all sources should be changed to consistently use the human-friendly names, but that's a separate issue.

Oct 23 2017, 11:38 AM
alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

This is even worse. You can't new[] and then free(). Please follow the suggestion on just embedding the prefix directly, if desirable.

Oct 23 2017, 10:22 AM
alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

The patch is not acceptable in the current form. This includes fixing the memory leaks.

On PowerPC, three different output forms have to be supported:
(1) register name without percent on Darwin
(2) plain register number on AIX
(3) register name with percent OR plain register number on anything else
I don't think there is a big reason for supporting the second option of (3) though. The least amount of change is to introduce a predicate that checks for !Darwin && !AIX and then prints the % in the assembler printer. It is better to just pass down the target directly than deciding in the higher layers which forms should be choosen.

Oct 23 2017, 8:17 AM
alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

A few general comments:

  1. You should add reviewers to this review. At the minimum @hfinkel, @kbarton and @echristo. Maybe someone from FreeBSD if this affects them.
  2. Why do we need to change the default and get the existing behaviour with an option? Why not the other way around?
  3. Is this syntax accepted by all the assemblers (I think LLVM for PPC runs on FreeBSD as well, but I have no idea if FreeBSD returns true for isOSLinux()? We don't want to produce assembly that we can't assemble.
Oct 23 2017, 8:15 AM
alexandreyy updated the diff for D39016: Add Percent Symbol In PPC Registers for Linux.

Update according to review comments

Oct 23 2017, 7:54 AM

Oct 20 2017

alexandreyy added a comment to D39016: Add Percent Symbol In PPC Registers for Linux.

ping

Oct 20 2017, 4:36 AM

Oct 17 2017

alexandreyy created D39016: Add Percent Symbol In PPC Registers for Linux.
Oct 17 2017, 11:56 AM

Oct 5 2017

alexandreyy added a comment to D38323: Enable breakpoints and read/write GPRs for ppc64le.

Looks fine to me. Sorry about the delay.

@eugene should be able to help you commit this.

Wrt. the extra register context discussion, I believe you will need to implement an extra class or two when you get around to debugging core files, but that should not be necessary right now. (And yes, linux now uses lldb-server for local debugging as well).

Oct 5 2017, 11:27 AM
alexandreyy added a comment to D38323: Enable breakpoints and read/write GPRs for ppc64le.

Hi,
Could you review/approve this patch, please?
I do not have commit permission.
I will add other register sets later.
Thanks! ;)

Oct 5 2017, 5:24 AM

Oct 3 2017

alexandreyy added a comment to D38323: Enable breakpoints and read/write GPRs for ppc64le.

Are these changes ok?
I am implementing the read/write functions for the other registers.
And I will add it later.

Oct 3 2017, 6:24 AM

Sep 29 2017

alexandreyy updated the diff for D38323: Enable breakpoints and read/write GPRs for ppc64le.

Remove duplicated structs and change register set types

Sep 29 2017, 12:15 PM
alexandreyy added a comment to D38323: Enable breakpoints and read/write GPRs for ppc64le.

Looks fine. One main questions for new linux archs in particular: is linux using the lldb-server to debug these days even when debugging locally? If so, then this patch only needs to implement both a native register content and not the lldb_private::RegisterContext subclass.

Sep 29 2017, 12:05 PM

Sep 27 2017

alexandreyy created D38323: Enable breakpoints and read/write GPRs for ppc64le.
Sep 27 2017, 11:25 AM