IRC logs for #openrisc Wednesday, 2014-09-17

--- Log opened Wed Sep 17 00:00:56 2014
poke53282My plan for tonight is, to increase the time of reasonable sound output from 5 ms to 10ms :)00:38
-!- Netsplit *.net <-> *.split quits: simoncook, rah, mboehnert, knz, olofk, xlro01:48
-!- Netsplit over, joins: mboehnert01:54
-!- Netsplit over, joins: simoncook, rah, knz, olofk, xlro01:54
stekernolofk: I'm experiencing a regression after I pulled the latest wb_streamer stuff, and I see full & wr_en asserted at the same time, so I suspect that it's this:
stekern...but I think that <= should be correct though, so the root cause might be somewhere else03:16
olofkhmm.. I wonder how to get this behaviour in the test bench05:19
stekernin my setup, writing is many magnitudes faster than writing05:23
stekernthan reading05:23
olofkcool. I'll start with that05:24
stekernI had some more observations, wait I'll call them back from the back of my brain05:25
stekernhello? ..ello? ..ello?05:25
olofkOh my god! It's full of stars!05:26
olofkWhat's your register settings?05:27
olofkburst size, buf size..05:27
stekernburst size = 8, buf size = 64 KB, FIFO_AW = 1005:33
olofkI found another set of params that seem to break the sim. I'll try those first05:33
olofkhmm.. the IRQ line is never raised05:35
stekernit is in my setup at least05:43
stekernI can rebuild with the <= and give you a capture of the failure05:45
poke53282no luck today. No sound output06:05
olofkDoh. Just realized why my test bench doesn't work06:45
stekernhmmm... why is cnt only 5 bits?07:07
olofkThat's a good question. FIFO_AW = 1007:08
stekernah, it's just because signal tap doesn't update what you log just because the size changes07:10
olofkah ok07:10
stekernI think it's safe the all the bits that we can't see is '1'07:11
stekern*safe to assume07:11
stekernI think I know what the problem is though, cnt can't hold 2**FIFO_AW07:15
olofkstekern: When I lower the readout speed if the FIFO it gets stuck here as well07:45
olofkehmmm. how do I take a screenshot in X?07:46
LoneTecholofk: many options, for instance using graphicsmagick: import -screen filename.png07:47
olofkFound xfce4-screenshooter07:47
olofkLoneTech: Thanks. I didn't have graphicsmagick installed though, so I'm going with xfce4-screenshooter07:48
olofkstekern: I think you might be right regarding cnt
stekernolofk: I'm doing a build with [DEPTH_WIDTH:0] cnt now07:54
stekernand the same change in the writer07:55
olofkI tried that too08:00
olofkStill seems to be a problem somewhere08:01
olofkThere is still a write when FIFO is full08:02
olofkActually I think the problem just moved08:03
stekernyes, I've got that too08:05
olofkThe full flag is actually set on 2^AW-108:06
olofkSo maybe the <= statement in ctrl is wrong after all08:06
olofkOr should be <= 2**FIFO_AW-1 (which is the same thing)08:06
stekernhmm, but the FIFO should be able to hold 2^FIFO_AW entries08:07
olofkYeah, I realized that too08:07
stekernwhy is it then signaling full "too early"08:08
olofkDon't know08:08
olofkMight be the part that I added :)08:08
stekernwhat did you add?08:08
stekernmight be that the storebuffer fifo signals off-by-one08:08
olofkCould be. I suspected the fifo_fwft08:09
olofkBut I see now that full is coming directly from the fifo08:09
stekernit wouldn't matter in mor1kx if it did, since writes are pushed back on full08:09
olofkNo, it only matters in this case since we are relying on the fifo count08:10
olofkAnd assume that the FIFO can hold the new data08:11
olofkActually, we're not using the full flag at all08:11
olofkIn my case, I have burst size=8 and FIFO depth is 3208:13
olofkFIFO starts to fill up when there are 24 entries left. So far so good08:13
olofkYep. There is something fishy in fifo or fifo_fwft08:17
olofkI fucking hate FIFOs.08:19
olofkManually counted all writes and reads, and the counter seem to be consistent, so I suspect fifo.v right now08:31
olofkwrite_pointer == "where to write next entry" and read_pointer == "address of next data to read" =08:32
olofkCheating a bit and looking at other FIFOs, they all seem to use an internal counter08:44
olofkMight have to do that. I think that read_pointer == write_pointer for both the empty and full conditions08:44
olofkFound another solution now where the pointers are one bit wider, and MSB is used to detect empty or full08:47
olofkLooks like this works
olofkA few lines shorter
stekernthat has the added benefit that you get rid of the prev_read_pointer09:19
olofkSo it might even save a few flops09:19
stekernI'll do some tests with mor1kx09:20
olofkIt works in my tb now, but doesn't seem to guarantee anything, so I'm holding off pushing the patch until then09:20
olofkTime to pick up baby09:20
olofkDoes anyone want to consider themself as a maintainer for the de0_nano FuseSoC port?10:28
olofkI'm basically want to commit some patches and wonder if anyone want to comment on them10:29
* stekern feel like olofk's staring at him10:47
stekernolofk: I still get we & full conditions with the code you pasted10:51
olofkI never looked explicitly for that10:57
olofkDid you update the streamer?10:58
olofkI can take a look at it. Just need to do some other patches first10:59
olofkMy orpsoc-cores working tree is a mess right now10:59
stekernyou only have one orpsoc-cores working tree that's a mess? lucky bastard11:06
olofkHmm.. can't make that happen here11:14
olofkfull & we11:14
olofkDid you increase the cnt signal everywhere as well?11:15
olofkI have a local change that increases it in fifo_fwft module port11:15
stekernmmm, so do I11:17
stekernit's signaling full when cnt = 0x2011:19
stekernbut the fifo should be 2^1011:20
stekernI'll bring in the read/write pointers into the signaltap11:20
olofkCan you look at the synthesis logs (or send them over to me)11:21
olofkWant to ensure that FIFO_AW is set correctly11:21
stekernboth the read and write pointer are 10 bits, so I think it should be11:22
olofkThat's even weirder11:22
stekernI mean 11 bits11:23
olofkLooking at the pointers will be very interesting11:24
olofkI wonder if the counter gets out of sync11:28
stekernarea wise it didn't make much difference, a couple of more LUTs and a couple of less regs11:30
olofkSounds reasonable11:31
stekernwrite_pointer == 0x410 and read_pointer == 0x01012:07
stekernoh, but the cnt value I said before was wrong... signaltap had added cnt[10] and cnt[4:0] to the bus...12:15
stekernok, now this makes more sense. it's 0x40012:48
stekernso it has wrapped around12:48
stekernor not wrapped around, it's what it should be12:49
stekernok, I found the reason, I had forgot to save the change of the cnt wire in the writer top module...14:01
mor1kx[mor1kx] skristiansson pushed 1 new commit to master:
mor1kxmor1kx/master 1db1b36 Stefan Kristiansson: store_buffer: fix full_o signaling...14:06
olofkIt works now?14:15
stekernI'm still building, but I'm fairly certain that that's it14:17
stekernand I'm confident that your fix to the fifo full signal is correct14:18
stekernI gave you some creds in the commit msg btw ;)14:19 you can stop thinking that I'm a douchebag that hurried out that commit to make it look like you based your fix on my commit instead of the other way around =P14:20
olofkI was prepared for that, so I installed a back door in the code14:26
stekernI noticed, that's why I changed it slightly14:27
stekernit works now14:27
olofkHmm.. might need to go to work tomorrow. It's difficult to analyze RF signals without a spectrum analyzer14:28
olofkEven if you have a really really fast multimeter14:29
_franck__FYI: building the current or1k-src repo without --disable-werror on a 64bits machine trigger an error. The solution is here:
_franck__so, for now --disable-werror is required for 32-bits _and_ 64-bits machines15:36
_franck__(unlike it is said on the wiki)15:36
poke53282olofk: I was wrong. Framebuffers supports mode setting. But not the ocfb16:13
rjosb0_: regarding all these environment variables, i think its better if scripts just let artiq populate an ArgumentParser with artiq options (-v, --dump...).16:36
rjodamn. wrong channel.16:36
-!- Netsplit *.net <-> *.split quits: ed-jones17:00
stekern_franck_: FYI, building binutils from upstream doesn't have that problem (neither on 32-bit nor 64-bit)17:00
-!- Netsplit *.net <-> *.split quits: O01eg17:00
-!- Netsplit over, joins: ed-jones17:00
-!- Netsplit *.net <-> *.split quits: jeremypbennett, poke53282, rjo17:01
stekernor umm, I thought you were referring to something else... scratch what I said17:01
-!- Netsplit over, joins: O01eg, jeremypbennett, poke53282, rjo17:02
-!- Netsplit *.net <-> *.split quits: bentley`17:02
-!- Netsplit over, joins: bentley`17:03
stekern_franck_: can you elaborate, what in the ml message is the solution? and what is the problem?17:03
_franck_stekern: I should have been less affirmative. I had this error:
_franck_then later in the thread it says that the patch I linked here is the solution18:35
_franck_however, the only thing I did is to add --disable-werror to make it work18:36
stekernbut, haven't those been committed to upstream?18:40
_franck_may be, I don't know, I used or1k-src from github18:40
_franck_that might be the problem18:40
stekern(which in no way makes your claim that or1k-src might need the --disable-werror false)18:41
stekernbut I built binutils from or1k-src about a week ago without that flag18:42
_franck_it may depend on the version of GCC used to compile binutils18:43
stekernoh, right... sorry, it said with 4.9.x in the msg you pasted18:48
stekernI've got 4.8.218:48
poke53282Arghh, looks like the whole sound output is more complicated than expected. Maybe I have to change more than expected.21:23
poke53282I found something funny:21:24
poke53282#define SNDRV_PCM_RATE_CONTINUOUS       (1<<30)         /* continuous range */21:24
poke53282#define SNDRV_PCM_RATE_KNOT             (1<<31)         /* supports more non-continuos rates */21:24
poke53282what's this?21:24
poke53282stekern: Did you ever compile a native gdb?22:35
poke53282or ltrace?23:31
poke53282well, the answer you will give to me is pretty obvious. But one has asked me if I can compile this tools.23:54
--- Log closed Thu Sep 18 00:00:57 2014

Generated by 2.15.2 by Marius Gedminas - find it at!