Page 1 of 1

[TM4C123] REPL debugging info

Posted: Sat May 11, 2019 2:22 pm
by ExXec
Hey,

I have a strange problem.
The REPL shows the debugging info, even though I didn't enable it.
And when I call disable_irq() in the main its gone.

Does someone have an idea?

It looks like this:

Code: Select all

took 8 ms                                                                       
qstr:                                                                           
  n_pool=1                                                                      
  n_qstr=3                                                                      
  n_str_data_bytes=19                                                           
  n_total_bytes=115                                                             
GC: total: 24192, used: 1200, free: 22992                                       
 No. of 1-blocks: 11, 2-blocks: 5, max blk sz: 40, max free sz: 1432  
It comes from here: https://github.com/micropython/micropyt ... xec.c#L127

Re: [TM4C123] REPL debugging info

Posted: Fri May 31, 2019 2:48 pm
by ExXec
anyone?

Re: [TM4C123] REPL debugging info

Posted: Fri May 31, 2019 4:05 pm
by dhylands
It would be useful to know what debugging information you're talking about.

Re: [TM4C123] REPL debugging info

Posted: Sat Jun 01, 2019 5:12 pm
by ExXec
Sorry.
It looks like this:

Code: Select all

took 8 ms                                                                       
qstr:                                                                           
  n_pool=1                                                                      
  n_qstr=3                                                                      
  n_str_data_bytes=19                                                           
  n_total_bytes=115                                                             
GC: total: 24192, used: 1200, free: 22992                                       
 No. of 1-blocks: 11, 2-blocks: 5, max blk sz: 40, max free sz: 1432  
It comes from here: https://github.com/micropython/micropyt ... xec.c#L127

It would be great if you could tell me how to disable that. Maybe modify the exec_flags and/or the repl_display_debugging_info?

Re: [TM4C123] REPL debugging info

Posted: Fri Jun 21, 2019 12:49 pm
by ExXec
Does nobody know?

Re: [TM4C123] REPL debugging info

Posted: Mon Jul 08, 2019 10:20 am
by ExXec
push

Re: [TM4C123] REPL debugging info

Posted: Mon Jul 08, 2019 12:25 pm
by jimmo
I think we need more information?

The thread title implies you're talking about a port to the TM4C123, so I'm guessing you're only seeing this on your board? Can you link to a repo that has the code with this issue?

When do you see this - I'm guessing on every statement?

Re: [TM4C123] REPL debugging info

Posted: Mon Jul 08, 2019 8:15 pm
by ExXec
yes, on every statement,

I searched for every occurence of the variable repl_display_debugging_info, but none of them seemed to be suspicious.

i based my port mostly on the pyboard, so it "should" be roughly the same. (read: I copied a lot and didn't change it if it worked)

link to repo:
https://github.com/ExXeptional/micropyt ... ts/tm4c123

other causes I thought of:
something in the mpconfigport.h
Maybe its the -DDEBUG flag for the compiler?
I borked the initialization in the main()
a stray interrupt is called for whatever reason ( bc it doesn't happen w/ interrupts disabled)

if you need information please ask, but I don't know what else to tell you right now.

Re: [TM4C123] REPL debugging info

Posted: Mon Jul 08, 2019 10:01 pm
by dhylands
If repl_display_debugging_info is set to a non-zero value then I think it will do what you're seeing.

repl_display_debugging_info is declared static, and winds up being in the .bss which means that its the responsibility of the runtime library code which calls main to clear the entire bss.

So the first thing I would look at is whether your bss is being cleared.

The next thing that could cause it would be some type of memory overwrite from some other C code which just happens to trample the memory location containing repl_display_debugging_info

Re: [TM4C123] REPL debugging info

Posted: Tue Jul 09, 2019 1:04 pm
by ExXec
So the first thing I would look at is whether your bss is being cleared.
Yes this was the problem.
It was locked behind a #ifdef and the define was accidentally removed somehow.

Thank you, I would've never looked there.