IRC logs for #openrisc Monday, 2014-05-26

--- Log opened Mon May 26 00:00:05 2014
-!- FreezingAlt is now known as FreezingCold02:38
veprbl 05:41
stekernblueCmd: ok, so it "works" in the sense that an executable is produced06:07
stekernah, righ, that you already said here: https://github.com/bluecmd/or1k-debian/issues/3406:09
_franck__stekern: info registers your_register_name/or_group_name06:47
_franck__"maint print reggroups" if you want to show group names06:48
stekern_franck__: ok, so what's "my_register_name" for epcr?07:12
_franck__epcr I guess :)07:16
stekernhmm, I think I tried that, but it didn't work07:18
_franck__http://repo.or.cz/w/openocd.git/blob/HEAD:/src/target/openrisc/or1k.c07:18
_franck__reg names are here07:18
stekernI don't have access to anything to test on right now, so don't believe anything I say as a fact07:19
stekern;)07:19
stekernok, I see that they are in the "system" group07:20
stekernI seemed to only be able to access the once that had NULL07:20
stekernbut I probably did something wrong then07:20
stekernhmm, maybe I forgot to try with the 0 appended to epcr07:22
_franck__you can also access all registers with openocd07:23
olofkGeneral orpsoc-cores system improvement. Implement a bootrom that is preloaded with _franck__'s blinky code07:57
olofkI've done that for my local lx9 microboard07:57
olofkExtra bonus points for reading a pin at boot to decide whether to run the blinky code or load from an onboard Flash07:59
_franck__a bootrom associated with a assembler source file would be great. Then fusesoc would compile the file and generate the rom content08:33
LoneTechstekern: epcr0 perhaps. the spec indexes them because of the multicontext stuff08:33
stekernyes, that's what I meant with "forgot to append 0 to epcr"08:44
stekernolofk, _franck__: isn't blueCmd working on something like that?08:45
_franck__stekern: I think so08:45
stekernof course when I have inserted more debug instrumentation for the RCU stalls, they refuse to appear...08:47
blueCmdI am! I have scripts! :)09:24
LoneTechblinky (:09:25
blueCmdwhich reminds me that I should read up on olofk's RAM/ROM thing09:25
_franck__blueCmd: is your work already integrated with fusesoc core description file format ?09:26
_franck__blueCmd: I'm talking about your bootrom work09:34
LoneTechhm. it ought to be possible to merge functionality of fusesoc and migen somewhat09:55
LoneTechsomething for later. barely started learning about both.09:58
blueCmd_franck__: nah, I don't think it can be10:25
blueCmd_franck__: I want to change it so that cores can generate files, but I haven't gotten around to it10:25
blueCmdso that you have a couple of boot.S for generic stuff as shuffling from EPCS or you can just do your own in the systems/ dir10:27
blueCmdwb_intercon should use that as well - no point in having autogenerated files checked in10:27
stekernI think we should have those checked in, but it should also be possible to generate them when you build10:30
stekernat least as long as wb_intercon is a fast moving target...10:31
blueCmdwhy?10:47
blueCmdthat doesn't make any sense10:48
blueCmdthen you hide when you introduce breakage10:48
blueCmdif you change wb_intercon and change the output it should be your resposibility making sure you don't break the other targets10:48
blueCmd(which is why we need CI testing :P)10:49
stekernno, you hide breakage from users10:49
blueCmduntil said user wants to re-generate the intercon10:49
stekernthe CI tests should of course autogen all the files10:49
blueCmdwhat would you earn by having the generated files in RCS?10:50
stekernthe point I just made, hide breakage from (regular) users10:52
LoneTechautogenerated files can be helpful to get releases started with less dependencies; for instance, not requiring the assembler to build the boot rom while porting to a new board. and such releases belong in revision control as tags or branches.10:52
LoneTech(not necessarily the same repo, though)10:53
stekernyeah, I'm not arguing about the boot rom10:53
stekerneventually, I agree, the wb_intercon generated files should go too10:54
LoneTechthe intercon is part of the build system though.. having it prebuilt would risk missing a reason to rebuild it10:54
blueCmdstekern: eventually?10:54
stekernyes, when it's "stable"...10:54
blueCmdLoneTech: +110:54
stekernit's even broken as is now10:54
blueCmdstekern: hah, well - that will never be :)10:54
blueCmdchanges will always be introduced, no?10:55
LoneTechthat's what freezes/releases are for; limiting the set of bugs to fix to reach stable10:55
stekernyes, but not changes like the one with the resize port10:55
stekernand you can change/fix things without breaking "ABI"10:57
stekernI think it's pretty close to that, but my point is just, I think we should hang on to the generated files for just a while longer10:58
stekern(+ we have to fix all the boards that will break with the current wb_intercon_gen)10:59
stekern(+ we have to fix wb_intercon_gen to generate right sized ports for the resizer)11:00
stekern...then you have 'eventually' (perhaps =P)11:01
blueCmdwhich is my point :(11:05
blueCmdwe shouldn't have pushed a broken wb_intercon_gen (it should have been a branch)11:06
stekern...and then we would just point people to that branch, and then later explain "no, don't use that anymore"11:07
stekernto be fair though, it's not really broken now11:08
stekernbut what's the problem? the big job is to get the infrastructure to auto-generate the files in there, whether they are autogenerated by default or not is just a small detail11:10
stekernwe could even do it so, that if the builder finds a wb_intercon.v file in the system dir, it doesn't overwrite it by default11:12
stekern...or well, if the generate statement is in the core files, it's not even an issue11:28
blueCmdofc this discussion is moot until we implement the feature, so if the point in time where we autogenerate files is later than when wb_intercon_gen is stable - then everybody will be happy12:06
stekernright ;)12:07
blueCmdso, let's implement it slowly!12:07
blueCmdand procastinate it12:07
stekernturning on icache makes things crash in a lot more spectacular way12:08
stekern...also, slightly less subtle ways12:09
blueCmdstekern: re13:04
blueCmd(wait, I pressed enter too soon)13:04
blueCmdhttp://dc387be60423e03e.paste.se/13:05
blueCmdor1k-linux-gnu-gcc -g -O2 -fPIE -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Os -fomit-frame-pointer -D_FORTIFY_SOURCE=2 -fPIE  -Wl,-z,relro -Wl,-z,now /srv/build/main.c -pie -o pie-test13:05
blueCmd./pie-test13:05
blueCmdstekern: execute!13:05
stekern(unstable-or1k)root@wonka:~# gcc -g -O2 -fPIE -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Os -fomit-frame-pointer -D_FORTIFY_SOURCE=2 -fPIE  -Wl,-z,relro -Wl,-z,now /main.c -pie -o pie-test13:12
stekern/main.c: In function 'main':13:12
stekern/main.c:2:2: warning: incompatible implicit declaration of built-in function 'printf' [enabled by default]13:12
stekern  printf("Hello\n");13:12
stekern  ^13:12
stekern(unstable-or1k)root@wonka:~# ./pie-test13:12
stekernHello13:12
stekernblueCmd: you can have my working pie if you give me your working atomics ;)13:13
_franck__(wb_intercon) not tested on hardware but generated files look good: https://github.com/fjullien/orpsoc-cores/commit/b0e64c84add4192aee03c65cb5b77aae3f3999f713:18
blueCmdstekern: haha, http://openrisc.debian.net/qemu-or1k-static.atomic13:33
blueCmdstekern: if you could upload that pie somewhere I would be grateful :)13:34
blueCmdstekern: apparently updating qemu to qemu.atomic worked for mafm and the new libc614:05
stekernblueCmd: are you insinuating that it might be a pebkac issue?14:33
stekerngiven that parts of that rootfs have been built by me with voodo and black magic, I'm not going to argue...14:34
stekern_franck_: I think that looks good (haven't tested though), I wonder why the < 32 is needed?14:36
stekernI mean, why can't everything be produced with the < 32 code?14:37
_franck__I also wonder :)14:37
_franck__you're right, I just copied what I did some lines after14:38
_franck__we can remove this test14:38
stekernI think we should try to be compatible with the bus widths > 32 too14:39
stekernbut that's of course another issue14:39
stekern...but just that we shouldn't assume that the "normal" bus width is 3214:40
stekernblueCmd: chrooting into it with that qemu works14:47
stekern...and apt-getting libc6 too14:48
stekernI must have screwed something up when I built the qemu-or1k-static here...14:49
stekernblueCmd: pie? https://i.chzbgr.com/maxW500/5045393152/h0E1DA433/14:56
blueCmdstekern: :(15:19
stekernI still have the issue with or1ksim/real hw though15:20
blueCmdyeah that's weird15:21
blueCmdor rather, it's probably in the 'failed' loop15:21
stekernI tried checking where it "stalls", but I needs some finer tools than just halting the processor and checking where it is15:21
stekernbecause, the kernel is happily chewing on doing something15:21
blueCmdit might be something like overwriting the registers used to hold parameters inside the loop (i.e. not marking them as early clobber)15:22
stekernI'd like or1ksim to break on U flag15:22
stekernwhat loop are you speaking about?15:22
blueCmdl.lwa, l.swa, l.bnf 1b15:23
stekernah15:23
blueCmdI tried to be careful with the modifiers in the insns but maybe I missed something like that15:23
blueCmdit makes sense that it would be something related to that at least15:24
blueCmdbut that probably means it's something totally different15:24
stekernyes ;)15:24
stekernI've tracked down my smp crashes to "something screws up r3 now and then"15:25
blueCmdthat's easy15:25
blueCmdjust move r3 somewhere else!15:25
stekernheh15:26
stekerndid you get around to test to boot your rootfs in or1ksim?15:28
stekernhmmm... E: Failed to fetch http://openrisc.debian.net/pool/main/s/systemd/udev_204-8_or1k.deb  404  Not Found15:32
stekernwhen trying to reinstall udev15:32
stekernnvm... after apt-get update it found it15:34
stekernhmm, doing a new apt-get dist-upgrade after that started to pull in a lot of new systemd stuff15:36
stekernoho, now it breaks in new fascinating ways: http://pastie.org/921916515:39
stekernblueCmd: what do you have in your sources.list now?16:18
olofkI see that there's a lot of things to reply to. Excellent :)16:27
olofkLoneTech: I want to be able to use migen to generate parts of the SoC in FuseSoC. I'm also looking to rebuild the old misoc with fuseSoC16:28
olofkAnd regarding wb_intercon16:28
olofkwb_intercon is very loosely coupled to the build system and that's intentional16:29
olofkAnd I think it's fine(ish) to let 32 bit data be default, but it needs to be a lot more flexible so we can have wider buses16:29
olofkA complete rewrite is tempting. It's extremely messy code now16:30
olofkBut the config format is probably fine as it is16:30
olofkand regarding bootrom generation and stuff. Storing precompiled stuff is fine if it cuts down on the deps.16:31
olofkand extra mega bonus points if someone either:16:31
olofk1) patches binutils to make the verilog backend for objcopy spit out files with wider data16:32
olofk2) Comes up with a way to let wb_ram read a byte hex file and still map it efficiently to the FPGA resources16:33
blueCmdstekern: http://941272f59399f4fa.paste.se/16:34
olofkoh... and onani! Excrements!16:34
blueCmdstekern: word of warning: do not install the coreutils that is in http://openrisc.debian.net/debian, place a hold on the one you already have16:34
stekernummm... how do I make sure of that...16:34
blueCmdalso, binutils should be from http://openrisc.debian.net/pool/main/b/binutils/ to have all TLS patches16:35
blueCmdecho 'binutils hold' | dpkg --set-selections16:35
blueCmdwhat to do for coreutils is left as an exercise ;)16:35
stekernhow do I now that the ones I have now is good?16:36
blueCmdthat's harder :P16:37
blueCmdfor coreutils it's easy since it's a specific version16:37
blueCmdfor binutils the two repositories contain different stuff with the same version16:37
blueCmddpkg-query -l 'binutils'16:38
blueCmdhi  binutils                2.24.51.20140425 or1k             GNU assembler, linker and binary utilities16:39
blueCmdhi  coreutils               8.21-1           or1k             GNU core utilities16:39
stekernah, well, let's assume the one I have is good16:39
stekernunrelated to this, but I get: libasound2 : Depends: libasound2-data (>= 1.0.27.2-4) but 1.0.27.2-3 is to be installed16:40
stekernok, I don't have that coreutils16:41
stekernhi  coreutils                    8.21-1.2            or1k                GNU core utilities16:41
blueCmdI get a lot of weird stuff with cp and other utils with that version (error messages that you probably remember that we 'debugged')16:49
blueCmdstekern: are you sure you have the [arch=all] line that I have in your sources.list?16:50
stekernyes, I'm sure I have it in /etc/sources.list ... This is what you get for doing 5 different things at the same time :(16:53
blueCmd/etc/apt/sources.list16:57
stekernI know16:57
blueCmdsorry :(16:57
blueCmd:P16:57
stekernnot your fault that I suck at multitasking16:58
blueCmddid you find the issue?16:59
stekernwith libasound? yes, that I copied your version into /etc/sources.list instead of /etc/apt/sources.list17:03
blueCmdhaha17:08
blueCmdnow I see17:08
stekernit still stalls in or1ksim though17:23
stekernI want to see where...17:23
stekernif I'd put a little l.nop 8 in init17:26
olofkAnyone else having trouble with fusesoc? I can't get it to work at all right now18:33
olofkIt just prints the help text18:33
stekernI haven't pulled in a while...18:33
olofkDon't! :)18:33
olofkMust have fucked something up with my command line improvements18:34
stekernhmm, I think I just found a bug in mor1kx18:34
olofkhmm, I think I just found a bug in fusesoc18:36
stekernwho's next! ;)18:37
stekernunfortunately, this means that my not-so-subtle fails were due to a bug in the cache refill code... so fixing that will not remove the subtle failures :(18:38
olofkFalse alarm. The FuseSoC bug was a bug that I had introduced locally18:51
stekerna little house bug18:52
blueCmdI feel like coding python today19:28
blueCmdolofk!19:28
blueCmdwrite as much as you can about how you want the cores to register themselves and that shall be done19:29
stekernblueCmd: it's not much, but it's all I've got: http://git.openrisc.net/cgit.cgi/stefan/linux/commit/?h=smp19:39
stekernto make up for the pie disappointment19:39
blueCmdhaha. factories. I'm sorry olofk, but I laugh at code that uses factories in python19:40
olofkblueCmd: What the hell is wrong with my factories? :)19:52
olofkIt's one of the very few design patterns that I know of, and I'm damn proud of them!19:56
olofkI even got a few singleton classes :)19:56
blueCmdolofk: because you can just do importlib.import_module(my_nice_string)19:56
blueCmdthat's the power of python, and you should use it :)19:56
blueCmdolofk: I'm reworking some things that you might want to pull - I'm going to preview them to you and give you a chance to say yey/nay before I do any huge amout of work with them19:57
blueCmdolofk: if you want to cry a bit, download pep8 and run it on the code ;)19:58
stekernfirst I crushed olofk's dreams of multiple inheritence and now you take away his factories, take it easy with the poor guy!19:59
blueCmdhah, I don't compromise with code quality :)20:03
stekernto be fair, pep8 complains about silly things in some cases20:09
stekernlike the tab here: https://github.com/olofk/fusesoc/blob/master/fusesoc/build/quartus.py#L1420:09
blueCmdright, it's not perfect - but it's damn better than to not use a linter in a multi-person project20:10
stekernoh, certainly... same goes for checkpatch.pl in the kernel20:13
stekernI wouldn't go as far as calling a coding style checker a 'linter' though ;)20:15
blueCmdhm, no?20:16
blueCmdmaybe the one we have at work is a bit more sofisticated, but it's called a linter and does mainly style checking20:17
stekernmaybe it's just me that associates the linter word wrongly20:18
stekernI associate it with "static code analyzing to find bugs"20:20
blueCmdolofk: http://aa7f0ededbef1f7b.paste.se/20:21
blueCmdolofk: then again, if you want to log all functions you can use sys.settrace also20:25
blueCmdor just do 'python -m trace bin/fusesoc'20:32
blueCmdor just do 'python -m trace -t bin/fusesoc' *20:33
olofkblueCmd: I think we should get rid of the function trace stuff. It was done by an old colleague early on. I've been removing bits and pieces of it when I've been updating code20:40
blueCmdGood20:42
blueCmdI'll do a clensing then20:43
olofkBut I liked the decorators20:43
blueCmdsure, but if the functionallity isn't needed - let's not add it :)20:43
olofkBut maybe we could decorate something else?20:43
blueCmd:D20:43
blueCmd@log20:43
blueCmdstekern20:43
blueCmdlook how nice he is now!20:43
stekernwho? where?20:44
blueCmdolofk: I only get --help when I run stuff :(20:44
blueCmdstekern: I applied a decorator on you20:44
blueCmdhm20:45
stekernok, a smile dekorator20:45
blueCmdolofk: false alarm! ;)20:45
olofkblueCmd: I think I was affected by the same bug earlier today. All AttributeErrors are caught in the top-level20:47
olofkI knew it was a bit dirty, but I did it for some reason that I can't remember now20:48
blueCmdolofk: http://d87ad5e75d8f0847.paste.se/20:48
blueCmdolofk: http://fde99f5601d1bb4e.paste.se/20:49
blueCmdthose are my first two patches I want to merge :)20:49
blueCmdolofk: you have to review faster! it's now 4 commits: https://github.com/bluecmd/fusesoc/commits/master21:02
mor1kx[mor1kx] skristiansson pushed 2 new commits to master: https://github.com/openrisc/mor1kx/compare/e0e2f058e3eb...3dbbd601202421:03
mor1kxmor1kx/master bd5d95f Stefan Kristiansson: cfgrs: set Architeture Version Reg to 1.1-rev021:03
mor1kxmor1kx/master 3dbbd60 Stefan Kristiansson: cappuccino/fetch: prevent burst signal on regular bus accesses...21:03
stekernI thought for a second that I had found the heisenbug21:27
stekernbut it was just one among others... http://git.openrisc.net/cgit.cgi/stefan/linux/commit/?h=smp&id=5c6f2df075b9320628240a8f9f0884a69c7f8eaf21:27
olofkblueCmd: Sorry. Can't merge. I haven't seen your license transfer agreement yet21:51
olofkAhh.. I see how you did got rid of the factory with importlib21:56
olofkThe providerfactory was particularly ugly. I think I did that one first21:57
blueCmdRight21:57
blueCmdI'm doing sections now :)21:57
olofkBut I'm not sure why you want to remove the base class?21:57
blueCmdolofk: why do you want it?21:57
olofkDon't you fucking touch my sections submodule :)21:57
blueCmdit's not a submodule anymore ;)21:58
olofkWell, I thought it could do general base classy stuff...like... I don't know21:58
olofkCan't think of anything right now, but I definitely think that the provider classes would want to share some code22:01
olofkGot to sleep now, but I'll probably cherry-pick a few of your patches straight away tomorrow22:02
blueCmdolofk: we can have a talk of why it doesn't matter for python tomorrow - it's a very common mistake to do if one has done a lot of other OOP programing before22:03
blueCmdpython is a bit special in that regard22:03
blueCmdolofk: I hope you don't feel stomped upon for me doing this22:04
olofkblueCmd: No worries, I'm eager to learn new stuff. But I might not agree on everything. Convine me tomorrow :)22:05
olofkConvince22:05
blueCmdofc!22:05
olofkI'm going to make a new project that no one else can commit to, and that will have multiple inheritance and decorators and factories and you can keep your stupid importlib22:08
blueCmdhaha22:08
blueCmdolofk: and blackjack and hookers?22:09
olofk:=)22:09
blueCmdolofk: stekern: http://2b22ad86cec9b307.paste.se/ something like that is what I'm thinking22:40
blueCmdI just need to figure out a way of supplying configuration values (which input to use for bootram, what the name of the wb_intercon config file is, and so on)22:42
blueCmdmaybe something like: http://0229edd899cce107.paste.se/22:45
blueCmdhttps://github.com/bluecmd/fusesoc/commit/0e391de954caefaf68b80046eb5ce30121f5731823:50
blueCmdRFC23:50
blueCmdgood night23:50
--- Log closed Tue May 27 00:00:07 2014

Generated by irclog2html.py 2.15.2 by Marius Gedminas - find it at mg.pov.lt!