« first day (930 days earlier)      last day (4020 days later) » 

9:00 AM
AWW TITTIES
I changed a fundamental part of the engine again
20 year recompile, here we go =/
 
"better recompile my 700 header project"
 
@ThePhD Why are you insisting on making it so big? Out of curiosity.
 
?_? seriously I do not get you
 
I'm not insisting on making anything big.
That's just the structure and nature of the engine.
Also, it's not 700 header files >__>
I cleaned it up.
It's... um
 
wait, the nature of it is to be bloated?
 
9:01 AM
I'll take 400 headers for $100
 
buy 300 headers get 300 free
 
Oh.
Well, scratch that.
 
I found this too.
 
I am focusing hard on making my stuff shortest that it can possibly be
 
I'm at 964 .h files.
 
9:02 AM
congrats
You increased it by 33% from the last time I saw it
 
36 more to becoming unmaintainable ever.
 
I think that's mostly because of my Decl.h/.h structure.
 
@Rapptz I am amazed by the quantity, with a few doubts towards quality
 
So really, it's about half of that, plus 100.
 
@ThePhD ?
 
9:03 AM
So.... ~580ish
 
you mean ".inl" files?
 
@Rapptz There's Decl.h, .h, and .inl
.inl is template functions only
 
user142019
boo
 
.h includes either just .Decl.h or BOTH .Decl.h and .inl
.Decl.h is declarations only
 
what the fuck are you doing
 
9:04 AM
even declarations for the template functions.
@Rapptz What the C++ compiler should've done for me millions of years ago.
 
user142019
@Rapptz Don't bother, he's just ThePhD'ing.
 
that's retarded
I am disappointed.
 
=[
It is not.
 
Why don't you do .hpp/.cpp for your regular stuff and .h/.inl for your template shit
 
@ThePhD that's your solitary opinion
 
9:06 AM
I do have .cpp
The .h system is just for the declarations
 
do you still have singletons?
 
All of my singletons have since been removed.
There was only one: the Audio System.
Since I cleaned it up and beefed up AudioDevice, it works much like GraphicsDevice and any others.
Make one, use it, throw it away when you're done.
 
mhhmmm
tell me
how many loc you write per day
 
These days, not many at all.
Well, actually, it depends...
But usually, not a lot.
 
so how on earth are you able to fill 964 headers?
 
Xeo
9:10 AM
lol
 
Thread, WorkerThread, ThreadPool, and Log/Logger were the last big LoC commits.
 
How did this fuzzy FP feely answer accrue so many upvotes while containing repeated and glaring syntax errors? I hope this poster doesn't use c++ in his day job... — sehe 2 mins ago
 
Not all of the headers are big.
Some of them are really tiny.
 
@sehe where are the syntax errors exactly
@ThePhD so why are they even headers?
 
@BartekBanachewicz std::tie<>
 
9:12 AM
please tell me you are not using one header per class always
 
@sehe Man.. I remember I was going to answer that question but decided against it :(
 
@Rapptz doesn't it work for pair?
 
you don't do std::make_pair<T,U>()
so you don't do std::tie<T,U,V>()
 
oh fuck now I see it
 
I see no reason to fold these header files.
 
9:12 AM
what a retard
my brain locked :/
 
I have to find a needle in a haystack
I don't know how to even approach this :/
 
std::find :D
 
@ThePhD wait you have your own thread class?
 
@BartekBanachewicz Yes.
 
Hah you found. Chat loader for ne just now
 
9:14 AM
@Rapptz No, I have to debug, it's not just a matter of using a computer to find this.
 
@ThePhD I... I... I don't know what to say.
 
sbi's comment was pretty nice too
 
I have to find this bug in the software, but you can't simply debug this, because millions of possible options
 
@BartekBanachewicz It provides cooperative cancellation and some extra status information about the thread. It also allows me to requeue work on a single thread, and manages the internal std::thread without any hassle.
 
also, hi @sehe!
 
9:15 AM
AFAIK, std::thread has no outlets for cooperative cancellation.
 
did you reimplement std::async perchance?
 
std::async sucks.
 
Ohai
 
How's you?
 
Besides std::async sucking, no. I instead wrote my own ThreadPool.
 
9:16 AM
> there was a time when nobody knew that Darth Vader was Luke's father
hi :)
 
@ThePhD which, let me guess, doesn't suck, huh?
 
@Rapptz It's not that bad.
Hi all, BTW.
 
Reading :) my connection is prone to drop any second - and I don't even mind it that much :)
 
@BartekBanachewicz It accomplishes it's job, handles edge cases extremely well, and supports cooperative cancellation for any running jobs.
 
@ThePhD so how come you haven't sent that to C++ comittee yet?
 
9:17 AM
It also hands out std:: compliant structures, so the interface is compatible with std::async and friends (std::future's and such)
 
@sehe Your lucky it's just your connection. Ours, the whole damned power.
 
user142019
@TonyTheLion whhaaa!!
 
@ThePhD out of curiosity, how long does a recompile actually take for you?
 
@BartekBanachewicz Why? I'm sure the C++ committee is already writing it's own std::thread_pool by now. They're also writing their own std::concurrent_queue.
@jalf I haven't timed it recently...
 
9:19 AM
@ThePhD well, roughly
are we talking 2 minutes or 2 hours ;)
 
@ThePhD Boost doesn't have that yet?
@ThePhD after every build VS will show you the time.
 
@jalf Full recompiles usually chomp some ~10 minutes of my day away?
 
@BartekBanachewicz If it was 2 hours I'd kill myself. D:
I miss the days of as-low-as 8-second rebuilds, using Unity Building. =[
 
@ThePhD something is very wrong.
 
9:20 AM
@ThePhD you should speed up your build process :)
 
Our 10-year gigantic project at work takes 7:00 at peak
 
user142019
@ThePhD I'd kill myself anyway if I had to use MSVC.
 
so you are doing something very wrong if it takes 10 minutes
 
My biggest guess is because I'm not very frugal with the std:: headers.
 
or you just include everything in headers even when you don't need to
 
9:22 AM
@BartekBanachewicz Yeah, that was what I was wondering. We have around 2.3MLOC, and it takes 7 minutes on Windows a beefy machine, and a couple of minutes on Linux
 
o.0
What steroided projects are you guys running?
 
we spawn like 50-100 builds a day usually
our division has around 25 I think machines dedicated only for builds
and around 300 for tests
 
@ThePhD what do you mean? We just try to keep build time down. How you structure your code, and what you include and when makes a huge difference
 
also every dev has anything from 2 to 10 workstations under his desk (counting laptop into it)
 
9:24 AM
@BartekBanachewicz 300? WTF.
 
@BartekBanachewicz oh wow. We have two build servers, I believe. :)
no, three
One for each OS, Linux, Mac and Windows
 
We barely have 1 build machine
:|
 
well that's just our team.
other teams have similar numbers
 
@jalf =[ I wish the compiler would order those things nicely for me.
So I would never have to. =[
 
I would show you the photo of the labs but we are forbidden to take photos there :)
 
9:25 AM
meh
 
@ThePhD It's not so much the order of includes (although that can make a difference too), but how many files they're included in (directly or indirectly)
 
well Intellectual Property is protected highly
 
@BartekBanachewicz can you tell us where you work? Sounds like a big place :)
 
@jalf Intel Technology Poland
 
ah cool
 
9:26 AM
yea I am quite proud to work there :)
also I really like the people and the job itself
 
Hm.
Well.
Truth be told, I know why my build takes so long.
It's just really A MILLION DIFFRENT fileS.
 
which file.
 
That's messing everything up, that is.
 
<includealljustforkicks.h>?
 
No idea what you're talking about~
 
9:29 AM
hrhrhr
 
Well, he exists
 
@TonyTheLion if you can afford a lambo you can afford batman mask too :P
 
oh crap I stopped on ambient occlusion
 
@ThePhD consult this and you'll know how much time to spent optimizing it. ;)
 
9:35 AM
Hm.
Compilation starting to speed up...
 
I've realized I use nested classes a lot.
 
@ThePhD Don't you have that really shitty .inc structure where you basically include everything, ever, repeatedly?
 
@DeadMG ... Wha?
.inc ?
 
I think he means .inl
 
No, I think he means a .h where you #include <theworld> #include <andtheuniverse>
And, maybe. >_>
 
9:40 AM
no
 
.inl sucks too
in fact your entire thing sucks
 
I seem to recall that you built your entire project so that everything was a header file and you included it all into one TU
 
That was how I did it before.
 
user142019
Validated.
 
Before Domagoj left he told me to separate all my shit out.
So I did.
Now I have regular TUs
 
user142019
Link or it's a Photoshop.
 
@ThePhD we all told you that.
 
user142019
Dankeschön.
 
requires Facebook account -> epic fail
 
user142019
 
9:43 AM
well why the fuck would you want to click on Fb link if you don't have Fb?
 
user142019
> The link you followed may be broken.
 
Oooh, hat guy is back.
 
... to view the content?
 
Xeo
@R.MartinhoFernandes Who?
 
@Xeo xkcd character.
 
Xeo
9:44 AM
ah
 
user142019
The guy with the hat.
 
Great, now we just need to OCR that and give to Google Translate.
 
Xeo
hrhr
 
5:45 AM and not asleep :(
 
9:45 AM
gee gee
 
dafuq is the ::: thingy
asm("LABEL_1:":::);
 
user142019
@LuchianGrigore it's for passing variables and options to the assembly code.
 
gcc specific?
 
user142019
Yes. RTFM.
 
yeah, you can have up to 4.
 
9:47 AM
no, the inline assembler syntax is Standard.
 
@R.MartinhoFernandes it's basically about how chrome sucks lately. Michał is a webdev and my flatmate.
 
user142019
@DeadMG Since… when?
 
user142019
Oh sarcasm.
 
no he's right kinda
 
user142019
Maybe. :|
 
9:47 AM
asm is a keyword in C++
 
lol
 
@BartekBanachewicz I switched to FF at home, cause Chrome kept crashing on me
 
I think anyway
 
user142019
@Rapptz Yes but what it does is completely implementation-defined, as well as the syntax.
 
sarc asm
 
9:48 AM
@rightfold a monad
 
@rightfold Well.. no shit.
 
@TonyTheLion I use beta chrome and it's quite stable tbh
 
Fuck Browsers, who need the Internet anyways?!
 
Also development in chrome is very good imho
When making OpenMOBA i wouldn't want any other IDE than Chrome
 
@TonyTheLion Certainly not us.
 
9:49 AM
I should go back to it someday.
 
last I checked, this chatroom was implemented via telegram
 
@DeadMG carrier pigeons
 
@BartekBanachewicz It does.
The Internet is not the cables...
 
@DeadMG Haha
@BartekBanachewicz lol
 
Fuck
964 errors ;~;
Across 500 different files
 
9:51 AM
fail
 
auto getChunkAccessor(OuterChunkCoord const& coord) {
    auto it = data.find(coord);
    return [&it](InnerChunkCoord const& c){ return it->second.get(c); };
}
 
wat
 
apart from missing C++14, is it legal if data is a map?
 
No assert of validity of it. Fail.
 
well fuck it, assume it's always valid
 
Xeo
9:52 AM
Ref-capture of local variable. Fail.
 
no
 
@Xeo damn.
 
WTF is that?
 
@BartekBanachewicz No, you don't. I see no assert(it != data.end()) there.
 
I want to speed this up a bit
@R.MartinhoFernandes it's outside.
 
9:52 AM
wut
 
tightly coupled class
 
Outside is the wrong place :S
 
@BartekBanachewicz how can it be outside when the find is inside?
 
please, screw validity for a while, this is about speed
3
 
ahahahah
 
Xeo
9:53 AM
...
 
lol ~performance~
 
speed won't matter when results are invalid
 
Xeo
Worst argument you could've made, man.
 
that was on purpose :P
 
this ^
 
9:53 AM
anyways.
 
firstly, you're wasting a cockload of time with a map when you need unordered_map, since map is log(n) and unordered_map is 1.
 
@DeadMG aaaaaaaaa.
yes.
 
> cockload
lol
 
and secondly, you need to switch out the allocator or plain load the map's data into a sorted vector
those are the real improvements
your trivial micro-optimizations in that function body won't have any effect whatsoever
 
9:54 AM
@R.MartinhoFernandes needs less ++
 
thanks Puppy. exactly what I needed.
 
@Rapptz lol, no way.
 
@DeadMG they would amortize that log(n), but you are obviously right
 
@R.MartinhoFernandes everyone knows fast.c++ is slower than fast.++c
 
Xeo
lol
 
9:55 AM
@BartekBanachewicz You can't amortize that log(n), it is log(n) and that's that.
 
@Rapptz Oh, I thought you mean that oneboxing was failing because of ++.
 
@Rapptz But those are slower than fast.c
 
but it matters if it's called n times or n^3 times huh
 
no, not really
if you call a log(n) function, it's irrelevant how many times you call it as to what it's complexity is.
 
well it was a microopt.
 
9:56 AM
@R.MartinhoFernandes I forgot gists even oneboxed.
 
in fact, the more times you call it the worse the difference is going to be between log(n) and 1.
 
meh, I'll just make it an unordered_map as I should in the first place
 
just use a hash map, and use a proper allocator for it, and that might yield an improvement
 
@Rapptz For some weird reason, that one isn't ...
 
I always use unordered_map
 
9:57 AM
@Rapptz Same, I always default to unordered_map.
 
@BartekBanachewicz That's probably the one you want most of the time.
 
@DeadMG hm, what would be the "proper" allocator?
 
user142019
boo
 
also you need to define an std::hash for your thing
 
@Rapptz Even for small sets?
 
9:57 AM
@BartekBanachewicz Depends on the exact usage pattern. But you could start with an object pooling allocator, or a memory arena allocator.
 
@MarkGarcia ya
 
std::hash is stupid.
 
@MarkGarcia A map only beats an unordered_map for a map of 1 element.
 
@R.MartinhoFernandes :O Y so?
 
@Rapptz just got that error
 
9:58 AM
@Rapptz Could have a point. Scalability thingies and stuff.
 
for a map of 2-3 elements, they are equal; else, the unordered_map always wins.
 
so how should I hash my int triple?
 
@ThePhD Because it violates SRP. In a weird way.
 
S.. RP?
 
@BartekBanachewicz Depends on the intended semantics.
 
9:58 AM
@BartekBanachewicz boost::hash_combine.
 
Super Roadkill Project? :O
 
SRP: Salt River Project power and water
 
@ThePhD Single Responsibility Principle.
 
Single Responsibility Principle.
 
Xeo
Single-Responsibility-Principle.
 
9:59 AM
std::hash is more like "Half Responsibility Principle".
 
@DeadMG can you elaborate on what I might want?
 
Xeo
lol
 
@BartekBanachewicz Not without knowing your intended semantics, no.
 
@R.MartinhoFernandes because you have to define it yourself?
 
what's wrong with std::hash? It does one and only one job- hashing an object.
 
9:59 AM
@DeadMG it's a location vector (x,y,z)
 

« first day (930 days earlier)      last day (4020 days later) »