0:25 AM
Bertl_oO is now known as Bertl
0:42 AM
mithro
shenki: I think you have cut off the error there
1:24 AM
shenki: Timing: Completed - 82 errors found.
1:28 AM
shenki
mithro: why did i get different results to travis?
1:29 AM
mithro
shenki: I can't see the errors, so I can't see why it is different?
1:30 AM
shenki
mithro: okay. which log file do we want? i've closed the tab so i don't have the console history
1:32 AM
mithro
shenki: a couple of pages above that output would be useful
1:36 AM
shenki: as well, ISE gets confused sometimes
1:39 AM
shenki
ok, i'll rebuild
1:39 AM
mithro: should i delete anything before rebuilding?
1:39 AM
mithro
shenki: no need
1:39 AM
shenki
ok
1:39 AM
and this is what i want to type?
1:39 AM
make BOARD=atlys TARGET=hdmi2usb PROG=openocd gateware
1:44 AM
mithro
no
1:44 AM
you shouldn't need anything more than "make gateware" all the others are defaults
1:46 AM
shenki
k
2:24 AM
mithro: it worked this time :/
2:24 AM
mithro: thanks for your help ")
2:24 AM
:)
2:24 AM
mithro
shenki: good to see you trying things :P
2:28 AM
sb0 has quit
2:43 AM
Bertl is now known as Bertl_zZ
3:05 AM
sb0 joined the channel
3:05 AM
travis-ci joined the channel
3:05 AM
travis-ci
3:05 AM
travis-ci has left the channel
3:46 AM
sb0_ joined the channel
3:46 AM
sb0 has quit
4:44 AM
sb0_ has quit
5:14 AM
shenki
mithro: thanks :) now that i've got a hdmi2usb and a hdmi2eth build, i will test it tonight
5:15 AM
i want to demo the hdmi2eth to a friend
5:15 AM
mithro: can you help me with a c++ question?
5:15 AM
mithro: you were going on about const expressions the other day
6:21 AM
sb0 joined the channel
8:57 AM
mithro
shenki: I'm around know if you still need that C++ help
9:00 AM
sb0 has quit
9:05 AM
sb0 joined the channel
9:16 AM
shenki
mithro: i have this snippet of code
9:16 AM
static Target* const MASTER_PROCESSOR_CHIP_TARGET_SENTINEL
9:16 AM
= (sizeof(void*) == 4) ?
9:16 AM
reinterpret_cast<TARGETING::Target* const>(0xFFFFFFFF)
9:16 AM
: reinterpret_cast<TARGETING::Target* const>(0xFFFFFFFFFFFFFFFFULL);
9:17 AM
it's in a header
9:17 AM
and i want it to be a compile time constant
9:17 AM
gcc warns me that it's unused, which i thought it wasn't supposed to do for static const things
9:17 AM
(i didn't write the code. im trying to build it using a newer compiler)
9:22 AM
mithro
shenki: what C++ version are you compiling with?
9:24 AM
se6astian|away is now known as se6astian
9:52 AM
shenki: that expression isn't a valid const expression in older C++ versions IIRC
10:02 AM
shenki: Until C++11 things you think should be constant expressions are not
10:03 AM
rohitksingh joined the channel
10:10 AM
shenki
mithro: im not sure which version. let me examine the flags
10:10 AM
mithro: you suspect that if i do -std=c++11 it might work?
10:10 AM
mithro
shenki: It'll be closer to working :)
10:10 AM
shenki
heh ok
10:11 AM
mithro
10:11 AM
tpb
10:14 AM
shenki
mithro: the warning im getting is relating to an unused var
10:14 AM
mithro: i thought i wanted to fix it by making the whole the const
10:14 AM
coz normally in c++ you can have a static variable instead of doing #define?
10:16 AM
mithro
shenki: btw is the pointer const or is it pointing to something that is const, or both?
10:17 AM
can you past the whole error
10:17 AM
?
10:18 AM
shenki
it should be both
10:18 AM
it's not in the code as it currently exists
10:19 AM
mithro
I think you need more const in there :P
10:19 AM
shenki
yeah, that might be the issue
10:20 AM
then all of the call sites blow up :/
10:20 AM
but yeah, i think the issue is a long standing bug
10:20 AM
and gcc 4.9 has a bug where it doesn't produce any unused warning for it
10:22 AM
In file included from mdiafwd.H:34:0,
10:22 AM
from mdiamba.C:30:
10:22 AM
../../../../src/include/usr/targeting/common/targetservice.H:137:22: error: ‘TARGETING::MASTER_PROCESSOR_CHIP_TARGET_SENTINEL’ defined but not used [-Werror=unused-variable]
10:22 AM
static Target* const MASTER_PROCESSOR_CHIP_TARGET_SENTINEL
10:22 AM
^
10:22 AM
cc1plus: all warnings being treated as errors
10:23 AM
mithro
shenki: and you sure you are using it somewhere?
10:24 AM
shenki
well, yes and no. it's a header, so sometimes it's used and sometimes it's not
10:24 AM
depends on the c++ file
10:25 AM
but C++ is not supposed to warn about stuff that's static const, right?
10:25 AM
mithro
shenki: I don't see why it wouldn't?
10:26 AM
shenki
$ g++ -Wall -O2 -c a.cc
10:26 AM
$ echo $?
10:26 AM
0
10:27 AM
$ cat a.cc
10:27 AM
static const int a = 10;
10:27 AM
coz c++ developers use static const instead of #defines
10:27 AM
i dunno. perhaps im all confused
10:28 AM
mithro
shenki: but if you never use your #define anywhere?
10:28 AM
btw you shouldn't be putting that initializer in the header file
10:29 AM
shenki
ok. why's that?
10:29 AM
(i need ammo to tell the peeps who wrote it why they are wrong)
10:29 AM
mithro
shenki: it's equivalent to putting a function body in the header
10:29 AM
shenki
only if it's not const, right?
10:31 AM
static char const b = 1 ? 'a' : 'b';
10:31 AM
that line doesn't emit a warning
10:31 AM
static char* const b = 1 ? reinterpret_cast<char* const>('a') : reinterpret_cast<char* const>('b');
10:32 AM
neither does that
10:32 AM
but if i change the 1 to sizeof(void *) it does warn
10:32 AM
so that means that sizeof(void *) is not constant?
10:32 AM
which is bullshit, the compiler should know that at compile time
10:44 AM
mithro
I think the compiler doesn't see "sizeof(void*)" as a valid constexpr
10:44 AM
so it ends up actually allocating the value
10:50 AM
shenki
yeah
10:50 AM
i agree
10:51 AM
i proposed they use __SIZEOF_POINTER__, a builtin define that gcc provides
10:51 AM
mithro
shenki: if you look at a objdump of the output elf file, you'll see it
10:52 AM
shenki
good idea
10:52 AM
mithro
what does "sizeof(void const*)" ? or actually = "sizeof(TARGETTING::Target* const)" do?
10:53 AM
Bertl_zZ is now known as Bertl
10:53 AM
shenki: IE its weird to do the sizeof to a different thing you are reinterp casting from?
10:55 AM
shenki
it's a sentinel value
10:55 AM
so they're trying to make a pointer whos vlaue is -1
10:55 AM
ie, all 1s
10:55 AM
0xFFF....etc
10:55 AM
the sizeof is to find out of a pointer should be 64 1s, or 32 1s
10:55 AM
mithro
shenki: sure - I understand that
10:55 AM
shenki
right
10:56 AM
you're saying why not sizeof(Target *) ?
10:56 AM
mithro
8:16 PM <+shenki> = (sizeof(void*) == 4) ? reinterpret_cast<TARGETING::Target* const>(0xFFFFFFFF) : reinterpret_cast<TARGETING::Target* const>(0xFFFFFFFFFFFFFFFFULL);
10:56 AM
shenki
i guess it's a pointer, it doesn't matter what type of pointer you sizeof
10:56 AM
mithro
= (AAAA == 4) ? reinterpret_cast<AAAA>(0xFFFFFFFF) : reinterpret_cast<AAAA>(0xFFFFFFFFFFFFFFFFULL);
10:58 AM
Logically, all the AAAA should be the same I think
11:00 AM
shenki
yeah. that's good style
11:00 AM
but sizeof(<anything> *) will always be the same value
11:00 AM
so functionally there's no difference
11:01 AM
it could do sizeof(int *) for all it matters
11:06 AM
this code is just silly
11:06 AM
i give up
11:12 AM
mithro
shenki: depends on your architecture :P - on sdcc a sizeof(int*) != sizeof(int*) depending on which memory the int* is in
11:26 AM
sb0 has quit
11:45 AM
Bertl is now known as Bertl_oO
12:00 PM
shenki
heh, okay
12:06 PM
springermac_ joined the channel
12:06 PM
mithro: got the firmware loaded onto my atlys
12:07 PM
springermac has quit
12:12 PM
mithro
shenki: great, didn't we do that while I was at your place?
12:23 PM
shenki
yeah. but now ive done it by myself
12:24 PM
im trying to work out how the ethernet works. it looks like there's nothing on the lm32 for it
12:28 PM
mithro
shenki: yeah, I don't know very much about it
12:32 PM
shenki
ok
12:32 PM
mithro: what's our max res/framerate on usb these days?
12:32 PM
mithro
shenki: I'd start with seeing if the link light comes up / pinging it / etc
12:32 PM
shenki: 720p30
12:36 PM
shenki
yeah, i get the link light
12:36 PM
okay, thanks
12:50 PM
mithro
shenki: you should actually be able to set it up so that you can tftp boot the lm32 firmware
13:04 PM
shenki
mithro: i did see that. i'm poking around
13:05 PM
the ip is the same range as my home network