IRC logs for #openrisc Thursday, 2016-09-29

--- Log opened Thu Sep 29 00:00:16 2016
--- Day changed Thu Sep 29 2016
bandvigolofk: I successfully build NewLIB and uClinux toolchains under CygWin-64 with help of “old” guiding from OpenCores pages.02:57
bandvigOnly one trick: I used –disable-werror in each configure command line.02:57
olofkbandvig: That's good to know. I wonder if it's possible to do with mingw too02:58
bandvigolofk: And yet another peculiarity. If a source tree contains sim-links, they will be converted to files during cloning. How to fix it could be found by googling.03:31
olofkyikes. That's unexpected03:34
olofkI feel sorry for all the people who have to do development on windows machines03:34
Hoolootwoyes, it really sucks03:34
Hoolootwoover the summer I was forced to work on windows because the *specific* version of Modelsim we had didn't work on Linux03:35
HoolootwoI use Modelsim on Linux for school...03:35
olofkHoolootwo: Yeah. Mentor is horrible in that way. You have to pay a LOT more money to get the version that runs on Linux03:43
olofkBut then I found out that the license for the windows version also worked for the much more expensive Linux version too. And I happened to have that installed :)03:44
stekernI have gave up on trying to use things that are supposed to work on one OS on another, virtual machines works too well nowadays to bother03:53
stekerngames is maybe an exception, but then again, I don't play much games03:53
stekern... and we just "invested" in a gaming rig for my oldest son, so I can just lend that when he's away ;)03:56
stekernI tried playing an FPS for the first time in maybe 10 years, the new DOOM. It was pretty fun, but it reminded me why I don't play games much.. I suck at it03:57
HoolootwoI occasionally play with friends, but I'm not going to invest in a rig of my own, and I only run linux, so that restricts games somewhat03:58
HoolootwoI do enjoy, however, pretty much anything from zachtronics, but that's just glorified programming anyway03:59
stekernI need to point my kids towards that ;)04:00
ZipCPUAny suggestions for irctc916's need to compile gdb for or1k-linux-musl?06:04
olofkZipCPU: I think he needs gdbserver actually06:04
olofkOtherwise he would have to run gdb inside of or1ksim, which is most likely very painful06:05
Hoolootwoyeah, a gdbserver and/or stub of some sort seems like the best option here06:06
olofkUnfortunately, gdbserver is not that much used, and people have reported problems compiling it lately06:10
wallentoolofk: good question, I have honestly no clue about that10:06
shorneirctc916 guy seems aways, I havent tried or1k linux gdb, not sure if its supported10:50
shornemaybe r1k-*-linux*), but it seems that pattern is backwards10:54
shornethats in configure.tgt for gdb, but debug for newlib and linux is a bit different10:56
shornestekern: fyi I am still looking at this sigreturn stuff10:58
shornejust trying to really have a good understanding of all the entry code with respect to syscalls, signals, tracing and syscall restart10:58
shorneDo you know all of it?10:58
stekernI did have a grasp of it at some point, but I'd need to go back and look at it to remember11:16
shorneyeah, its just I think we are loosing reg state one some paths or something11:17
stekernhmm, can you make that statement more precise? ;)11:18
shorneits quite a bit to figure out where it is, I have a ptrace test, which tries to pull the regs when the syscall happens, but r11 shows 0x011:19
shorneok sorry, very late I am not typing clearly11:19
shorneI mean, the path is usually   head.S(exeception_entry save some regs) entry.S -> (_syscall_handler save more regs)11:20
shornethen call syscall11:21
shorneprocess any signals11:21
shornereturn from exception11:21
shornesorry, not really a question, just noting its a bit tricky peice of code11:22
shorneon one hand you want to save reg states to pt_regs11:22
shorneon the other hand you want to save as minimal as possible for speed reasons11:23
shorne... sleep time11:24
stekernright, syscalls are a bit special, since they are exceptions induced under "controlled forms" from userspace11:25
stekernand can in some regards be respected as just a function call into the kernel11:25
stekernr11 is special for syscalls, it holds the syscall number11:27
shornealso, there is the concept of caller and callee saved register11:29
shornebut, for syscall we just store to pt_regs r1-r12. But I would think the syscall might clobber r14-r30 (even) I guess that doesnt matter?11:32
shorneor I mean odds11:33
shorne... sleep11:33
stekernyeah, those are saved by the caller11:54
irctc634I asked the question about GDB but I was disconnected. In case it was answered please let me know!15:37
ZipCPUirctc634: Yes, you got some answers.  Check the logs, and ask back if you have further questions.15:38
irctc634Thanks ZipCPU!15:38
irctc634Is there a link for the gdbserver source?16:02
irctc634I tried compiling the gdb-7.2 and the two last ones(7.10, 7.11) and I am indeed getting compilation errors. My configuration flags are: --host=or1k-linux-musl --target=x86_64-pc-linux-gnu and I am using the latest config.sub16:56
irctc634All the errors are in linux-low.c16:56
shorneirctc634, I think you might need to use gcc 5.3.0 at least, are you using it?19:10
shorneBut the idea of debugging a linux process through the or1ksim gdb server is maybe not right19:11
shornethe or1ksim server exposes the code running on the processor for debug, so when you would connect debugger you would not be debugging a linux process19:12
shorneThe a or1k-linux-musl gdb would expect to debug linux processes in user space (so not go into syscalls, not into code).  This is not really supported by the or1k gdb as far as I remember.19:14
shorneAlso, to debug userspace processes you would need to start your gdb server on linux in userspace, not the or1ksim19:14
shornestekern: good news, got a report back from sebastian macke, it seems his claim that strace was not working was not right and it works.  So no issue with the latest patch.19:15
shorneI need to make sure it works though, because I cant get it working with my build19:15
shornebut good news19:15
stekernshorne_: yes, that's good news (and I had some recollection that this was the case)23:10
--- Log closed Fri Sep 30 00:00:35 2016

Generated by 2.15.2 by Marius Gedminas - find it at!