Guild icon
DDraceNetwork
Development / developer
Development discussion. Logged to https://ddnet.tw/irclogs/ Connected with DDNet's IRC channel, Matrix room and GitHub repositories — IRC: #ddnet on Quakenet | Matrix: #ddnet-developer:matrix.org GitHub: https://github.com/ddnet
Between 2017-11-20 00:00:00Z and 2017-11-21 00:00:00Z
Avatar
@HMH your threadsafe queue doesn't look threadsafe to me btw
13:56
and I don't know why it needs to be parametric over its container and the smart pointer it uses
13:56
can't it just store the element type directly
Avatar
that might be true, I guess you can enlighten me then ?
13:57
If it stores the element type directly I have found that this creates issues with ownership, thus the smartpointers
Avatar
in that case, can't you store smartpointers in the queue instead?
14:01
like instead of queue<T>, you just use queue<unique_ptr<T>> if you want it behind a unique_ptr?
Avatar
re thread-unsafety:
14:02
e.g. look at the Front implementation
14:02
it takes the lock, returns the reference and then releases the lock
14:03
but the reference can become invalid as soon as the lock is released
14:03
the calling function can't do anything with the returned reference AFAICT
Avatar
Yes, that is why there is GetLock
14:04
and that is also why I use a recursive mutex
14:05
So ideally you do something like this: { auto Lck = Q.GetLock(); Q.whatever() ... } // Lock released
14:07
The lock in there is to make reading always threadsafe but yes after returning things might have changed.
Avatar
but what use is the lock in the Front function?
14:07
if you can't use the reference anyway?
Avatar
It is probably not too useful to have these extra locks in there. Do you have an Idea to enforce locking, so it becomes impossible / hard to forget calling GetLock btw ?
Avatar
Sometimes eyes are blocked and you can't change
Avatar
abc
Avatar
@HMH you could force the usage of Queue through a wrapper which aquires the lock in constructor and releases it on destructor
Avatar
<dezzer> "/notice Nimda I am not a bot
Avatar
Nonono
Avatar
nonono?
Avatar
<dezzer> yesss
Avatar
have you ever tried Vivaldi browser?
Avatar
<dezzer> vivaldi is shit
22:52
<dezzer> opera is better
Avatar
vivaldi is closed-source
Avatar
why is shit
22:53
feels much better than google chroem
22:53
even if the same engine
Avatar
apparently opera is closed-source as well
22:53
wow, like it's 2000 again
Avatar
I don't know, what they did to google chrome
22:53
but it works like shit (edited)
Avatar
have you tried firefox? ^^
22:54
i tried opera, firefox, chrome
22:54
they are most popular
Avatar
have you tried the new Firefox tho
Avatar
that's why im asking what do you think about vivaldi
Avatar
@Beefywhale 😛
Avatar
what they changed?
Avatar
Everything
Avatar
suddenly, they are monster
Avatar
part of the rendering engine was rewritten in rust 😃
Avatar
of perfromance
22:54
or what
Avatar
performance and the look
22:55
it uses barley any ram
22:55
even with 100+ tabs open
Avatar
<dezzer> firefox is the best browser
Avatar
I have to say, that firefox looks great
23:05
I will test it
23:05
but first look, make me feel good
23:05
Firefox has different engine chrome yea? it's not chromium xD?
Avatar
<nemo2> firefox forever!
23:06
<nemo2> has been a mozilla fanboy since mozilla was a thing
23:07
Great, now i have to install firefox on android
23:07
and all will be great
23:07
I love Sync thing
23:07
that's why i used google
23:07
chrome
Avatar
<nemo2> eh. firefox sync has been around a looooong time
23:26
<nemo2> firefox worked awesomely on my ancient android 4 phone
Avatar
okok, fanboy
23:26
😄
Avatar
<nemo2> was the only browser that did GPU acceleration so scrolling worked ok. was funny to see people freaking out over smooth scrolling when chrome finally added it 😝
23:26
<nemo2> I was like. eh. have had this for years on my PoS phone
Avatar
chrome since 41 could do it too
23:27
but.. you had to enable it
Avatar
<nemo2> but... yeah, I was doing firefox sync against android like... 5 years ago.
23:28
<nemo2> and. had local encryption back then
23:28
<nemo2> Google only added it recently due to pressure and still isn't default
23:28
<nemo2> so everyone was happily uploading their wifi passwords to NSA
Avatar
Like, it does matter in this times
23:29
We can't do much about this 😛
Avatar
<nemo2> eh. make 'em work for it at least ☺
Avatar
Btw. i used firefox, but then firefox worked like a dinosaur
23:29
were very slow
Avatar
<nemo2> shrugs
23:30
<nemo2> no browsers were great back then. not even chrome
Avatar
so i switched to chrome, which were fast then
Avatar
<nemo2> and... depends on what you used it on
23:30
<nemo2> Chrome was fast on google properties, no shock
Avatar
but now I started lookin for new
23:30
browser
Avatar
<nemo2> but... consider nacl. google was pushing nacl due to limitations of their own JS engine
Avatar
and you told me that firefox were rewritten
23:30
and tbh, it works like a boss
23:31
Can i somehow, limit Ram usage of firefox?
23:32
or it's standard? :D!
Avatar
<nemo2> there are ram settings sure
23:32
<nemo2> for one thing, latest firefox is now using content processes, like chrome did before it
Avatar
Like wherE? Can't find
Avatar
<nemo2> you can reduce # of content processes
23:32
<nemo2> the fewer you use, the less ram
23:33
<nemo2> one interesting thing in nightly BTW is hovering over a tab shows process ID
23:33
<nemo2> so you can see when tabs are unloaded too
Avatar
Im not really familiar how browsers works
Avatar
<dezzer> wood pcs
23:33
<dezzer> confirmed
23:33
<nemo2> about:config
Avatar
I mean, inside
Avatar
<nemo2> I wouldn't recommend screwing w/ 'em too much
Avatar
i like to know how CSS is rendered and structure
23:34
thats all 😄
Avatar
<nemo2> is intended to be dynamic based on system capacity
23:34
<nemo2> dom.ipc.processCount;4 ← default number of content processes. cranking it down to 1 or 2 will save ram
Avatar
It will make browser less effective?
23:35
I bet yes?
Avatar
<nemo2> eh
23:35
<nemo2> not thaaat much
Avatar
don't screw around in about:config:D
Avatar
<nemo2> stuff gets unloaded pretty aggressively anyway
23:35
<nemo2> and you'll still have content process so rest of browser should be responsive
Avatar
at least if you want to blame the browser later
Avatar
<nemo2> but up to you
Avatar
I mean, it's more like for testing purposes
23:35
i have enough ram
23:35
Xd
Avatar
<nemo2> you can always try it in a test profile
23:35
<nemo2> firefox -no-remote -P test
Avatar
Okay i understand now, it create 7 process by default (edited)
23:36
for web, extensions, files and... one for general i guess
23:37
I will try with 3, I don't run much tabs at once
23:37
a lot*
Avatar
<nemo2> there's a bunch of things that make processes. browser interface, rendering process, web workers, content processes...
23:37
<nemo2> that config entry is for the content processes tho
23:38
<nemo2> btw, about:memory if you're curious what sites are being greedy
23:38
<nemo2> about:about for all about pages
Avatar
oh shit
Avatar
<nemo2> oh. also. did you ddnet guys notice we did a hedgewars release?
Avatar
are you from hedgewars devs?
Avatar
<nemo2> yesssss
Avatar
I tested that game, while using OBS haha
23:39
beceause we had a problem with Radeon carts
23:39
i mean, more like we thought it was problem with game
23:40
but, then we figure out, that OBS has troubles with SDL hooks
23:40
and crashes
Avatar
<nemo2> what is OBS?
Avatar
Software for streaming video
Avatar
<nemo2> ah
Avatar
Free and open sourcce
Avatar
<nemo2> interesting
23:40
<nemo2> we finally fixed our video encoding this release BTW
Avatar
<nemo2> only thing I've ever used is gtk-recordmydesktop
Avatar
its like, best free option.
Avatar
<nemo2> and have never tried streaming
23:41
<nemo2> but good to know
Avatar
I don't know any good alternatives
23:41
only paid one
23:41
I think, that almost every twitch/youtube streamer
23:41
use OBS
23:41
because of plugins and easy configuration
23:41
also good performance
23:41
anyway.. 😄
Avatar
<nemo2> why would streaming software need SDL hooks/
23:43
<nemo2> ?
Avatar
No idea, maybe to catch somehow scene
Avatar
<heinrich5991> nemo2: no, didn't see you did a release
23:44
<heinrich5991> link? :)
Avatar
I'm just user, but saw crash log
Avatar
<nemo2> heinrich5991: https://hedgewars.org ? ☺
Avatar
it was crashing on sdl hook
Avatar
<heinrich5991> Savander: if you want to be able to complain about the browser, don't change stuff you don't exactly know in about:config
23:45
<nemo2> heinrich5991: well. doing it in a test profile should be fairly harmless ☺
Avatar
heinrich, i revert changes
Avatar
<heinrich5991> good :)
Avatar
don't worry, I was just curious 😄
Avatar
<heinrich5991> nemo2: "There's no Mac OS version this time, but we hope to release one soon."
Avatar
you know, children's curiosity
Avatar
<nemo2> heinrich5991: can't find anyone to do the build ☹
23:45
<heinrich5991> I suppose that's due to no macos machines being available?
Avatar
does hedgewars is opensource?
Avatar
<nemo2> heinrich5991: well. unc0rr's coworker has one. and was trying to do build. but ran into some SDL lib loading error
23:46
<heinrich5991> have you thought about cross-compilation? I recently made it possible to cross-compile ddnet to macos
23:46
<nemo2> heinrich5991: heh. even more work that
23:46
<heinrich5991> not in the long run :)
23:46
<nemo2> hum. p'raps
23:46
<heinrich5991> or you could build on CI and use that artifact, that's a good idea anyway
23:46
<heinrich5991> (CI, I mean)
23:46
<nemo2> I remember setting up iOS toolchain under linux and that was super painful
23:47
<nemo2> and, Savander, yes, of course it is
23:47
<heinrich5991> nemo2: you need to change where the executable looks for its libraries
23:48
<nemo2> Savander: https://hg.hedgewars.org or use our download page for the release tarball
23:48
<nemo2> Savander: there's also https://hedgewars.org/kb/BuildingHedgewars but most of the non-linux build instructions are pretty sucky right now
23:48
<nemo2> heinrich5991: if you want to help... would be appreciated
23:48
<nemo2> esp by the OSX users ☺
23:51
<heinrich5991> nemo2: hedgewars uses hg? I wasn't able to wrap my head around that one :(
Avatar
Qt isn't paid library?
Avatar
<heinrich5991> no, it has an LGPL license IIRC
Avatar
On their website, i see big button
23:51
Buy QT
Avatar
<nemo2> on what website?
Avatar
qt.io
Avatar
<nemo2> Savander: BTW, if you're into privacy and maybe speed and don't mind totally ignoring heinrich5991's warning, I have some about:config settings I like to turn on - some are visible in Prefs too sooo
23:52
<heinrich5991> the URL sounds fishy :o
23:52
<heinrich5991> although it probably isn't
Avatar
I mean, i found it in google
23:52
first link
23:53
Qt | Cross-platform software development for embedded & desktop
23:53
And obviously, i can start Free trial (yea)
Avatar
<nemo2> Savander: privacy.trackingprotection.enabled;true turns on tracking protection always, not just in private browsing - may possibly break sites although I've never encoutnered this. You get a warning in URL if it is blocking things
23:53
<nemo2> Savander: speeds things up too obv
Avatar
yea, i saw that options
Avatar
<heinrich5991> just install ublock instead
Avatar
i enabled it ! 😄
Avatar
<heinrich5991> or access the option via the actual options, not about:config
23:54
<heinrich5991> "ublock origin", that is
23:54
<nemo2> heinrich5991: it used to not be exposed in settings so I have no idea where to find it there
Avatar
now there is privacy and security
23:54
tab in settings
Avatar
<nemo2> heinrich5991: btw, ublock/umatrix have a super annoying bug that's been driving me bonkers while I wait for the noscript port to be completed
23:54
<nemo2> heinrich5991: <noscript> tags are not flagged to be parsed, by them. bz seems to feel this is fail on their part
23:54
<nemo2> breaks a ton of sites
23:55
<nemo2> (breaks their fallbacks I mean)
23:55
<heinrich5991> ublock isn't about blockign JS
23:55
<nemo2> NoScript thankfully still works, in legacy mode. I'm following the bug on the full port. He made a webscript version too, no idea if it is more sensibly setup
23:55
<heinrich5991> it's more about blocking trackers etc.
23:56
<heinrich5991> you can use it in the script-blocking mode as well
23:56
<nemo2> heinrich5991: eh. toma-toe tomahto
23:56
<nemo2> heinrich5991: I was more interested in script thing. ☺
23:56
<heinrich5991> but since that's not their main business, there are bugs, apparently
23:56
<heinrich5991> I currently don't like having to unbreak every website I'm visiting
23:56
<heinrich5991> ublock doesn't break the websites ^^
23:57
<nemo2> heinrich5991: vast majority of sites I use work well enough w/ script blocking
23:57
<heinrich5991> well, not for me
23:57
<nemo2> heinrich5991: in fact on mobile I leave Js off most of time
23:57
<nemo2> good for security, privacy, bandwidth and battery
Avatar
Firefox has cool feature, a CLI
23:57
pref set privacy.trackingprotection.enabled true
23:57
cool command
Avatar
<heinrich5991> I usually browse a lot of different sites
23:57
<nemo2> eh. me too
23:57
<heinrich5991> security meh
23:57
<heinrich5991> since you're gonna enable it anyway if something breaks
23:57
<nemo2> surprising how many of them have usable fallbacks
23:57
<heinrich5991> privacy okayish
23:58
<nemo2> heinrich5991: well... sometimes I just fix their stupidity in stylish
23:58
<heinrich5991> bandwidth and battery ok
23:58
<nemo2> for example SMBC comics after-comic is JS toggled, so I made a stylish rule to always show it
23:58
<nemo2> minor things like that
23:58
<nemo2> I'd say I pretty much never toggle it on
23:59
<nemo2> heinrich5991: security.mixed_content.block_display_content;true blocks more sites for me actually
23:59
<nemo2> aforementioned SMBC for example ☹
23:59
<nemo2> if you use https everywhere they forcibly serve the comic as hardcoded http
Exported 255 message(s)