Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/asm: unactionable "invalid local variable type 0" #12658

Open
dvyukov opened this issue Sep 17, 2015 · 3 comments
Open

cmd/asm: unactionable "invalid local variable type 0" #12658

dvyukov opened this issue Sep 17, 2015 · 3 comments
Assignees
Milestone

Comments

@dvyukov
Copy link
Member

@dvyukov dvyukov commented Sep 17, 2015

cmd/asm produces the following error message on the program:

TEXT T(SB),$0
TYPE
asm: T: invalid local variable type 0

The error message should contain file name and line number, otherwise it is unactionable.

go version devel +5512ac2 Wed Sep 16 17:56:14 2015 +0000 linux/amd64

@robpike robpike assigned rsc and unassigned robpike Sep 17, 2015
@robpike

This comment has been minimized.

Copy link
Contributor

@robpike robpike commented Sep 17, 2015

The TYPE pseudo is not implemented by the assembler, nor was it implemented in the 1.4 assembler. The compiler emits it though. It needs to be brought into the assembler and parsed there. Or, more likely, not.

The error message here is not the real issue.

@dvyukov

This comment has been minimized.

Copy link
Member Author

@dvyukov dvyukov commented Sep 17, 2015

FWIW, I've got whole bunch of such messages without any location information:

    287 duplicate TEXT for C    
    198 C: invalid local variable type 0  
    176 T: invalid local variable type 0  
    126 duplicate TEXT for T    
    121 unknown TLS base register for linux  
     56 duplicate TEXT for _    
     24 "".: invalid local variable type 0  
     19 duplicate TEXT for "".    
     15 symbol T listed multiple times   
      3 duplicate TEXT for n    
      2 symbol O listed multiple times   
@robpike

This comment has been minimized.

Copy link
Contributor

@robpike robpike commented Sep 17, 2015

Those are all coming from the obj library, not the assembler itself. The obj library could profit by printing location information.

@rsc rsc added this to the Go1.6 milestone Oct 23, 2015
@rsc rsc modified the milestones: Unplanned, Go1.6 Dec 5, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.