« first day (1532 days earlier)      last day (3641 days later) » 

16:00
And sending a message back may also involve allocation.
Unless you reuse the memory from the incoming message.
lol
A continuous back-and-forth loop.
16:15
@StackedCrooked Most of them are, you know.
The cost of synchronization kinda ruins the effort of implementing an allocator.
not really.
depends on the allocator.
Maybe I should only allow thread 1 during even seconds and thread 2 during odd seconds :P
what is the allocator
I don't have a thread-safe one yet.
16:19
what is the general idea.
All I have now is a few simple prototypes.
Actually yesterday I had a look at Alexandrescu's small object allocator from Modern C++ Design.
It has a nice little chunk-based allocation algorithm.
@Puppy Basically I want a dispatch queue.
Tasks are dispatched on the queue and I want to avoid allocation with operator new.
std::packaged_task has a constructor which accepts an allocator and erases its type.
That's nice so I don't need to worry about encoding the allocator type in the queue's element type.
I've experimented with SBO as well.
That pretty much works actually. I don't even need an allocator then.
At least not for the task object. But placing it on the queue might involve an allocation.
I'm still doing all kinds of research really.
Ell
Ell
@StackedCrooked sounds risky :P
on a non realtime scheduled thing
I don't have an immediate problem that I need to solve. Up until now I solved each problem by taking advantage of something contextual.
And I want to learn new ways.
I really don't see what you're trying to achieve here, since you have no metric for success.
(my internet dropped out)
Hmm. Missed @sbi.
16:29
Like I often reuse objects instead of memory. Reusing an std::string object is better than only reusing it's memory. Just .clear() it and treat it as a new object.
seems to me that if the queue is of a type T, you can trivially solve this non-problem with boost::object_pool.
@Xeo you joining at Ben's?
@StackedCrooked Not noticably better and definitely more confusing.
stl allocators can be quite confusing you know
the C++11 minimal interface is quite simplified
but like I said, Boost already provides a thing for efficient allocation of a given type.
16:32
boost pool?
something like that
I don't really like the C++98 allocators.
They had to be stateless so you were forced to use a global pool.
In C++11 I can assign a pool object to an allocator.
me neither but their algorithm is nothing special.
Doesn't really need to be special.
object pool allocation is nothing more than a doubly-linked-list allocated in chunks.
and doubly-linked-lists can be made safe for concurrent mutation with some CAS.
16:37
If you only want to reuse memory then it's ridiculously simple. If you also want to have the allocations nearby in memory then it gets slightly harder. However, that's all without the thread-safety requirement.
thread safety requirement has nothing to do with it as long as you have a thread safe baseline allocator, which you do.
That ruins everything.
Portable solution for:: input within a time margin?
Maybe use <ctime> ? any ideas?
no.
If .allocate() and .deallocate() are called by different threads then weird stuff happens
:P
It crashes unrelated parts of the code :D
16:39
you only need to employ some CAS to protect against that.
it doesn't change the fundamental nature of the algorithm involved.
I'm not confident enough to implement lock-free algorithms.
Maybe if I had a good reviewer.
well let's see.
However, my colleagues won't be able to help me.
there's a good solution, but you don't want to implement it.
you're implementing a thing but you don't know if you've succeeded.
in fact, you don't even know if there's a problem.
what, exactly, is the point here?
from what I can see, you're just kinda waffling around not doing much
The thing with atomics is that you can have something that works perfectly fine for years and still have a race.
And I've been quite active actually.
user1804599
16:45
ok websocket y u no work
websuckit
user1804599
lol
well, if you want thread-safe performance, you don't have a choice.
either find a pre-packaged solution that can do this or crack out your atomics literature.
Xeo
Xeo
@R.MartinhoFernandes Ye, I'm about to leave for that
Hmm. Starting to think I should've watched Exodus yesterday.
Xeo
Xeo
16:46
though I noticed today is a holiday and I won't be able to buy anything to throw on the barbeque
I don't think there's barbecue this time.
Xeo
Xeo
oh, ok
how goes all?
grumpy
@Xeo my good! you germans really do like your bbqs
Xeo
Xeo
16:50
hm, I should get going
boy these adverts are so annoying and intrusive, I'm gonna buy from the other guys just to fuck these people off.
right
sent an email to that company detailing that they're worthless motherfuckers and should keep their grubby paws off my personal information and that I decided to buy from a different company.
FML.
I am confused by std::condition_variable::wait(lock, pred)'s semantics regarding the predicate.
Ell
Ell
17:06
@VáclavZeman it causes the current thread to block until the predicate returns true
kinda
the predicate is only checked when the condition variable it woken though
@Ell Right... So it is my code that is doing something wrong because it blocks... Hmm...
well, since the definition is "Blocks until true", then I don't think that the calling code blocking is doing something wrong.
welp saw The Interview today and it was actually not a bad film
Meh - ice crystals are forming above us and falling to the ground.
I went to an xmas fair today, it was nice
lots of food
@StackedCrooked Most of my multithreaded software works in a similar way - threads communicating via queues using pooled objects. No ctors, no dtors after startup:)
@AlexM. Nice indeed. I can't see anything past our doorway, it's just all white:(
17:20
it started snowing today
two days late but...
at least it's snow
@AlexM. I don't want the stuff. Our drive slopes and heavy snow means we often have to take a run-up to get out. That can be bad if something is coming on the main road:(
fed bailey?
user1804599
Ugh.
'umm prime;' - some doubt about type?
universal modelling mathematic
17:26
@Puppy He had a bit left over from yesterday, but his bowl is now empty. We'll feed him when we find him, (he's gone out in the snow).
lol
where are you, again? just rain here
@Puppy Derbys/Staffs border. It's snow all round midlands, from what I saw on MOTD:(
link?
Ell
Ell
Snowy here
Might have stopped though, can't tell
@Puppy Sorry I meant 'Football Focus'. Match of the Day is on tonite at 2300.
TBH, I can't see you watching either:)
OK.. Two-tone Bailey is back in.
@Puppy - Daisy likes the snow, or are her legs too short?
Ell
Ell
17:31
I thought you meant message of the day when I first saw :3
Instead of match
@Ell Oh.. that Unixy thingy on logon, lol
'message of the day' always used to piss me off. I kept taking it out of that funny '.' file that runs on login, but some bastard root admin/script kept putting it back again:(
user1804599
Coooool.
user1804599
IntelliJ completed pub to publisher: Publisher in a parameter list.
@MartinJames lol
rw permissions for all but you :P
@thecoshman I tried that, and other stuff. It started a permissions/privileges war with teh admins:(
17:46
@MartinJames No snow here. But she likes it.
Sysadmins are somewhat naive. They change their passwords over, and over again, but it's really no defense against a user who has hardware skills and physical access to their keyboards during shift work:)
lol
my backoff is not very exponential: 100us, 200us, 2ms.
But that works pretty good.
Actually, no, it sucks.
Polling is never optimal.
Ell
Ell
Yeah polling suxorz
it can work
17:59
Yeah.
Ell
Ell
Its frickin freezing
@Puppy Heh, well, I had the conditional reversed and it blocked because in my test the threads finished the work faster than it got to the conditional test. :)
hmm
KSP on Steam Sale.
holy shit- the front page offers last for 1 week?
FTL is on sale too for cheap and so is Banished
I may actually buy Banished since I already played the game basically to completion...
wait what the fuck.
all the Steam prices dropped when I logged in.
seriously, KSP was 25% off, now 40% off.
18:17
@MartinJames ¬_¬ put some sort of fork bomb into it
@Puppy I thought you had it?
@thecoshman I do, it was a frontpage deal.
@thecoshman lol. my contract was completed before my err.. 'relationship' with the sysadmins became unrestricted warfare with WMD;)
@Puppy I think the deals might have just changed, so went from 20 to 40 as you logged in
hm maybe
they did just put that round up
yeah I logged out and went back to the store, and they're still the more heavily discounted prices
you guys have no idea how tasty the shit I have here is. or maybe you do. dunno.
18:30
gonna admit, I have no idea how tasty shit is in general
not a fan of consuming human waste
@AlexM. It looks like an oatcake.
oatcakes look like crepes
yup, those are crepe look-alikes
@AlexM. Creepy
they look like burned pancakes
ignore the coconut flakes
the best kurtos has walnut sprinkled over it
like mine
blech nuts
@AlexM. Looks like some deep-sea life-form.
..but I still wouldn't turn one away:)
yeah the shape is interesting, it's made like this upload.wikimedia.org/wikipedia/commons/1/18/…
when I first ate one I thought "wouldn't it be best to fill up the empty space with more of it?"
Ell
Ell
18:39
You fools they're oatcakes
@AlexM. Oh nice! Would surely got for that.
Ell
Ell
Burned pancakes, what is the world coming to
they do greatly resemble burned pancakes.
@Ell If you haven't had oatcakes with bacon and cheese, you have missed out on a culinary wonder:)
Ell
Ell
@MartinJames I agree :)
18:41
wtf, Unity signaled a nullreference exception without me running the game
when did they add this
does it somehow simulate things in the background
or did it add some magic of its own to check for patterns
@Ell On a cold, winter's day in Hanley, I would go with oatcakes before pizza.
@MartinJames Sounds like bread but with a strange name.
@AlexM. It probably uses magic to check source code without even compiling
Ell
Ell
@MartinJames me too
@EmpereurAiman the code gets compiled on each return to the editor
18:43
So it should be the case
Btw, so you make 3d games? OR 2d?
it's a classic case (non-GUI editable public field in class not initialized but referenced from another script)
so it's probably a pattern match
bah
got a bunch of downvotes on Programmers for saying that static classes are moronic.
Ell
Ell
Why are they moronic?
because they're clearly namespaces but Microsoft apparently couldn't figure out how to implement having functions in a namespace.
static classes are a crutch for languages that dont have free functions
like C#
Ell
Ell
18:47
@Puppy and you think namespaces are moronic?
no.
I think that having two identical language features is moronic.
Ell
Ell
So don't say that static classes are moronic then :3
especially when one of them is completely redundant.
@Ell They are moronic.
Ell
Ell
No they aren't
I have just clearly stated why static classes are moronic.
Ell
Ell
18:48
Having two identical language features is moronic
That doesn't mean static classes are moronic
Right?
yes, it does.
user1804599
COOOOOOL
Ell
Ell
@Puppy why?
@Ell Because they're completely redundant and pointless.
Ell
Ell
Out of the identical language features, how do you decide which is moronic?
18:50
Prolly 'cos the Java smell.
simple.
one of them clearly expresses what it is and serves an obvious purpose.
the other one serves absolutely no purpose at all and is named very similarly to another feature that is completely and utterly different.
user1804599
Singletons ftw.
user1804599
They can be passed around an implement interfaces. (Y)
Ell
Ell
Go on
who, me or rightfold?
user1804599
18:52
> var ws = new WebSocket('ws://localhost:8080/'); ws.addEventListener('message', function(ev) { console.log(ev.data); });
undefined
> ws.send('subscribe:localhost/ping')
undefined
VM858:2 (localhost/ping,PT0.000043S)
VM858:2 (localhost/ping,PT0.000047S)
> ws.send('unsubscribe:localhost/ping')
/* no output anymore */
user1804599
^ I'm a heroine.
@rightføld I have no idea, the code tells me nothing. :D JavaScript?
What's this parsererror I am getting
yes.
^ should have been "no"
user1804599
18:53
@VáclavZeman Yeah. It listens for ping results on a web socket.
@EmpereurAiman It means that your brain is too slow to run the stack overflow chat message parser.
Where is the parser?
user1804599
On the web.
OK. @AlexM. Gamemaker Sucks.
we already knew
user1804599
18:55
You're even more confusing than sehe.
Ell
Ell
@Puppy you, sorry my WiFi is dodge
well, given that C# has namespaces, it's clearly moronic to add static classes instead of simply implementing free functions.
Oh wait, wrongly misspelled it
18:57
what's a static class? a class with only static functions?
@Columbo recureseverely
user1804599
A class that cannot be instantiated and contains only static methods and static fields.
user1804599
In C#, at least.
user1804599
In Java it's something else.
@AndyProwl räcürsiveli
Where the fuck is that implicit template parameter proposal!

« first day (1532 days earlier)      last day (3641 days later) »