« first day (921 days earlier)      last day (4044 days later) » 

1:00 PM
@R.MartinhoFernandes Are [| |] and $ splices?
 
@melak47 Do I really have to repeat my thoughts about Dx
 
Quotes?
 
@LucDanton [| |] are quasiquotes (i.e. more or less an AST literal) and $ is a splice, yes.
 
@R.MartinhoFernandes That's pretty awesome.
 
meh, asio should use <chrono> =\
 
1:01 PM
@BartekBanachewicz it's not surprising really - MS' implementation is built on DX11 compute shaders
 
@Abyx <chrono> is kinda weak
The templates are what feels most wonky.
 
weak?
 
@Abyx boost.org/doc/libs/1_53_0/doc/html/boost_asio/overview/cpp2011/… : "Boost.Asio provides timers based on the std::chrono facilities "
 
@melak47 But to get your compute results from OpenCL to OpenGL you need to pay. (which AFAIU is why they added actual compute shaders to OpenGL 4.3)
@ThePhD What?
@ThePhD What?
 
@Abyx Just using it, and the lax wording of the standard tha allows you to set the high precision clock typedef'd to the lowest precision clock ever.
 
1:02 PM
What?
 
@EvgenyPanasyuk oh, I didn't know, thanks
 
<chrono> is a marvellous piece of engineering. Don't you dare say otherwise.
3
 
=[
 
@R.MartinhoFernandes OTHERWISE!
 
@R.MartinhoFernandes yeah, but C++AMP seems like it's targetted more at general compute stuff, so actually using OpenCL and not OpenGL or DX11 compute shaders makes more sense IMO
 
1:03 PM
Hah!
 
@ThePhD That is pure bullshit.
 
@BartekBanachewicz also, please tell us what you think about Deus Ex :3
 
But even if it was not, you should blame your crappy implementation.
 
@melak47 first one was good
 
But here's the "lax wording" you referred to, for clarity:
> Objects of class high_resolution_clock represent clocks with the shortest tick period.
 
1:04 PM
@R.MartinhoFernandes Well, MSVC does exactly that.
MooingDuck is the one who actually dug into the MSVC headers and found the standards-conforming typedef for it. Lemme see...
 
I don't know what's lax about "shortest".
(That wording is wrong for other reasons, btw, should file a DR)
 
@R.MartinhoFernandes Surprisingly readable, too.
 
Feb 20 at 18:40, by Xeo
typedef system_clock high_resolution_clock; // MSVC :3
 
^ Best implementation ever. :D
 
1:06 PM
MSVC is weak and wonky. We knew that. <chrono> is great.
 
I hate MSVC and love it at the same time... It fucks me up so badly on the silliest shit.
 
Both are probably implemented with the same high-resolution timer
 
@CatPlusPlus Nope. <3
 
So, how do I file a DR again?
 
Xeo
@CatPlusPlus nop
 
1:07 PM
@ThePhD that is the best: liveworkspace.org/code/2OmpXq - static_assert(std::chrono::steady_clock::is_steady,"wtf?"); fails on gcc sometime...
 
Xeo
@R.MartinhoFernandes For what?
 
system_clock in MSVC's implementation is waaay low res.
 
Xeo
1ms
 
@ThePhD #include <boost/chrono>, namespace chrono = boost::chrono; FTFY
 
3 mins ago, by R. Martinho Fernandes
> Objects of class high_resolution_clock represent clocks with the shortest tick period.
Objects of class high_resolution_clock are worthless pieces of garbage.
All clocks are static only.
 
Xeo
1:08 PM
lol
 
system_clock has 100ns resolution it seems
 
Fuck you Reddit for cracking me up while I'm at work
 
> /* xtimec.h -- header for high-resolution time functions */
So there you go, that's your high-resolution timer
 
6 mins ago, by R. Martinho Fernandes
So, how do I file a DR again?
 
1:15 PM
Where to submit DR about some proposal?
 
nowhere
email them to the author
 
talk about efficient...
 
or post them on isocpp
 
isNormalized is known not to be closed under concatenation, but I can't find anything about substringing. I think I'll have to waste another bounty on SO.
Oh nevermind. I'm so silly.
"In contrast to their behavior under string concatenation, all of the Normalization Forms are closed under substringing."... Why didn't I think of grepping the spec first...
So, woot, plan not ruined.
 
1:19 PM
coding with Daisy on lap
 
tuple<void> is UB, I believe.
 
@R.MartinhoFernandes I can't see a way to instantiate it, but I also can't see that the type itself is invalid
 
Hmm, yeah. It should :P
 
1:27 PM
hmm
I think that I might be able to analyze concurrently
 
A tuple of bottoms
 
but no way I can codegen concurrently unfortunately
 
Buttuple
 
I need to generate chunks concurrently
minicraft could use some parallelism
 
... that awkward moment when you find a piece of code written months ago that should never have worked.
 
1:29 PM
@R.MartinhoFernandes Yep found that
actually, more like, it regressed and I didn't notice
 
cough unit tests cough
 
@R.MartinhoFernandes You wanna write them, be my guest
 
scumbag Curiosity.
 
1:31 PM
@DeadMG What do you mean? They are not worth your time?
 
more like, "I have so little time, if I stopped to write them, I'd never have time to do proposals, work, or prepare for Google, or implement new features".
 
You should hire an indian guy to write them then
 
especially considering that I have zero experience with them
 
The sooner you write them, the more you reap out of them.
 
I don't know how, and it's not easy to conceive of how I can unit test the output of my compiler
there are loads of possible and valid code generations of a given function
 
1:33 PM
@DeadMG what
@DeadMG test if the binary works obviously
 
@BartekBanachewicz What, prove the non-existence of UB?
 
Test observable behaviour (optimisations are indeed harder to test, but I doubt you need it right now).
 
Also test negative behaviour
 
Feb 26 at 12:37, by R. Martinho Fernandes
I fixed a bug in the Mono C# compiler once, so I'll just relate my experience. Their tests consist of C# files with full programs with a special comment atop that states whether the program should compile or not, and what error code should it produce if not. If it compiles, it is assumed it should run and exit with success (i.e. the program itself performs any assertions required).
Then they just have a special runner that extracts the information from those comments, compiles and runs each program and validates the result.
 
1:34 PM
@R.MartinhoFernandes Not all the bad code generations produce bad observable behaviour
 
@DeadMG but unit tests don't have to catch every possible error
 
no tests will ever get 100%
 
@R.MartinhoFernandes heh, interesting
 
@DeadMG No one said anything about having perfect tests or no tests being the only two options.
 
but they can check whether you get unexpected observable bad behavior
 
1:35 PM
@jalf True, but "Does it output correct code?" is pretty much the only thing I'm interested in finding out.
a testing scheme that can't tell me the answer to that question isn't very useful
 
@DeadMG Yes? So check whether the code it generates runs and generates the result you expected
 
and the easiest way to validate "correct" is check observable behaviour
people test that way all around the globe
they hit run and put in numbers
not perfect, but at least gives a rough estimate.
also that's the ultimate goal, no?
 
@DeadMG Well? For many, many forms of bugs, it would be able to tell you that "no, we did not output correct code"
 
Lundi tests already found an error IIRC :)
 
You can never prove the absence of bugs through testing. But you can prove their presence in many cases
 
1:38 PM
Here's an example from mcs: github.com/rmartinho/mono/blob/… It sets a compiler flag atop, and tests whether the code throws an OverflowException.
 
1
A: Providing an (empty) user-defined destructor causes compilation error

Lightness Races in OrbitWell, you said it yourself; when you provide a user-defined destructor, you inhibit the compiler's ability to generate things like an implicit move constructor. The contents of your user-defined destructor (be it empty or otherwise) are completely irrelevant. [C++11: 12.7/9]: If the definitio...

 
@BartekBanachewicz They have been useful from the very beginning!
 
haha, my work experience is showing up.
I actually think I've learned a lot about tests at work.
 
Ogonek tests have found countless regressions.
There was a time when I broke normalization at every other commit.
 
so what kind of infrastructure would I need?
 
1:43 PM
in Lua C++ API project, 1 min ago, by ankitmakwana
want to Learn C++ any body help me..?
 
I would never ever manually check those hundreds thousands of corner cases, and thus would certainly let bugs creep in unnoticed for... weeks? months?
 
anypony?
 
@jalf For a reasonable-sized system, that's generally true. It's worth noting, however, that for something like a single pure function, it can actually be false -- at least for something with a sufficiently limited range of inputs, you can test every possible input and verify correct results for all of them. I've done things like this a few times for things like fixed-point math functions.
 
@DeadMG CATCH?
hm, not exactly
 
@DeadMG All you need is a test runner and a convention for writing the tests, basically :P
 
1:44 PM
if you want to test outputs, there are tools used for online algorithm competitions
they are pretty damn fast.
 
the only way to know if the output of the compiler is incorrect is to parse the LLVM IR
 
For testing a compiler I don't think a "normal" unit test framework like Catch helps a lot.
 
unless you get an unexpected exception or something
 
@DeadMG No. You run the resulting program and test what it returned from main or something.
 
@R.MartinhoFernandes you can compile to library and then test that as a library.
@R.MartinhoFernandes just test stdout
 
1:46 PM
@R.MartinhoFernandes That result only means anything if the code generation worked correctly.
 
30 secs ago, by Bartek Banachewicz
@R.MartinhoFernandes just test stdout
 
@BartekBanachewicz And write parsing code in the tests?
 
if the compilation fails, test fails
 
if it didn't work correctly then the test might return anything
 
@R.MartinhoFernandes um?
 
1:47 PM
@DeadMG So what?
11 mins ago, by R. Martinho Fernandes
@DeadMG No one said anything about having perfect tests or no tests being the only two options.
@BartekBanachewicz What do you output on stdout?
 
@R.MartinhoFernandes Depends on what you want to test. Sum of two numbers?
 
I wouldn't want to invest a whole bunch of time and then find that the tests only cover the areas where I'm not having problems.
 
that's a valid point.
however, the more comprehensive the tests are, the better imo
 
Erm... what? How would you test that manually?
 
the fact you are not having problems now is irrelevant
 
1:49 PM
I guess that I could at least verify that the compiler can compile some programs without exception
 
Write tests now, you'll thank yourself later.
 
@DeadMG Were any videos made at the C++ meeting?
 
No compilers use unit tests no sir
 
@FredOverflow Not as far as I'm aware. I did see some guy taking pictures.
 
@CatPlusPlus lol
 
1:52 PM
@DeadMG In retrospect, how was the experience? I would imagine it as extremely cool.
 
@FredOverflow It was kinda cool but I think it could have been better
 
What celebrities did you meet except Stephan?
 
Herb
very briefly
most of the others I wouldn't really classify as celebrities
 
For example? I know some names.
@ScottW Many people struggle with that for their entire life!
 
hm, rasberry PI is cheap
when I get my paycheck I'll buy it
 
1:54 PM
@BartekBanachewicz That means you need to add a way of specifying what the expected output is.
 
Alisdair, Jeffrey, Jon, Herb, Stephan, Clark (the paper guy)
 
@DeadMG Jon Skeet? :)
 
@ScottW should I get A or B?
 
no
 
Jon Zoidberg?
 
1:55 PM
no
from Bloomberg
 
hmm B has 2x USB
 
and I also met Pablo (bloomberg) and Alan (dunno)
I saw Bjarne there, obviously
2
oh, I met Lawrence Crowl
 
a few others whose names I didn't catch
 
Xeo
Jonathan Wakely should've also been there, IIRC
 
1:57 PM
@DeadMG Did it cost you anything to attend the meeting?
 
@ScottW yeah
 
@FredOverflow His honour.
 
@FredOverflow You don't pay a fee to attend but I did end up forking over about £320 in hotel, travel, food, etc.
if I want to attend Chicago then I'll be paying about £500 just for the plane fare to get there.
 
@ScottW For me, that pretty much meant there was only one option.
 
end of September
 
1:59 PM
Did you have to register beforehand, or did you just show up and say "Hi, I'm DeadMG, inventor and implementor of Wide?"
 
beforehand, but a couple of people just showed up, I think
 
Did you get swag?
 
not really
 

« first day (921 days earlier)      last day (4044 days later) »