BinaryByter
notice how ACPI is the worst standard i've ever seen
BinaryByter
it is not even close
How about you implement ACPI on CLINL?
BinaryByter
Did you work with WinAPI? :D
no, I work on CLINL
BinaryByter
I would never do something as sinful as touching WinAPI
Anonymous
How about you implement ACPI on CLINL?
no i would not code in either C OR C++ for fun
BinaryByter
no i would not code in either C OR C++ for fun
Oh you are a coder for money only
BinaryByter
makes sense
Anonymous
nope
Anonymous
i prefer langauges like racket and haskell for fun programming
Anonymous
looking into lambda calculus
Anonymous
because these are still new to me
Anonymous
once i undertand them better i likely will get bored with them as well
BinaryByter
Okay so rule number two
BinaryByter
don't claim that you are better than qneko if you don't even know about lambda calculus
Anonymous
Anonymous
if he found a practical use for it i am more then happy to hear it
Anonymous
but i doubt that he did
BinaryByter
i do know about it but have yet to find a practical use for it
that separates a guy who worked for 7 years in robotics with the blockchain and AI and a 15 yo high schooler who codes for fun
Anonymous
Anonymous
firstly that is a shitshow
Anonymous
i find pthread_t easier to use
Anonymous
i like std::async
Anonymous
but that is annoying
Anonymous
you are likely refering to lambda functions in C++
BinaryByter
Anonymous
which i have done
Anonymous
but this is NOT EVEN CLOSE
L
i am beginner in c programming. what is best way to learn c? which book do you recommend to a beginner?
Anonymous
to lambda calculus
BinaryByter
#gooodgoogling
L
okay
Anonymous
you are likely refering to lambda functions in C++
which i had to do for both the restbed api in C++
Anonymous
as well as for several other things
Alignant
Anonymous
however lambdas in C++ still have a much simpler syntax and allows you to do imperative programming inside it
Ибраги́м
Anonymous
LAMBDAS ARE SYNTAX SUGAR
in C++ basically yes
Anonymous
Facepalm
does std::thread have semaphores?
Ludovic 'Archivist'
100 ?
Not that much in fact, I guess it may be due to hardware stream operations: ripemd160 494.92k ( 2.02µs) (± 4.33%) 224 B/op 1.18× slower MD4 585.44k ( 1.71µs) (± 3.79%) 224 B/op fastest MD5 575.92k ( 1.74µs) (± 4.23%) 224 B/op 1.02× slower SHA1 556.56k ( 1.8µs) (± 5.28%) 224 B/op 1.05× slower SHA224 491.0k ( 2.04µs) (± 3.62%) 224 B/op 1.19× slower SHA256 495.62k ( 2.02µs) (± 4.55%) 240 B/op 1.18× slower SHA384 416.7k ( 2.4µs) (± 3.40%) 256 B/op 1.40× slower SHA512 404.13k ( 2.47µs) (± 3.36%) 272 B/op 1.45× slower
Anonymous
last i checked it does not
Alignant
in C++ basically yes
Actually... average functions are sugar, cause names are gone after the compilation :D
Anonymous
names are not actually fully gone most of the time
Ludovic 'Archivist'
does std::thread have semaphores?
https://en.cppreference.com/w/cpp/thread/condition_variable
Anonymous
you need to do a few things for it
Alignant
names are not actually fully gone most of the time
Interface function names are not gone
Anonymous
semaphores act as mutexs and do not require a mutex inside the implementation of it
Ludovic 'Archivist'
no i mean a real semaphore
MMMMh in think not, but given implementation of one is less than 35 LoC it is not an issue
Anonymous
Alignant
A mutex is a binary semaphore
A recursive mutex is a semaphore, then? :D
Ludovic 'Archivist'
Anonymous
i mean sem_t
Alignant
Any mutex is one
No, I mean... identical to a semaphore?
Ludovic 'Archivist'
I rarely had to use semaphores, when I did need them, it was for reader/writer locks in a database
Anonymous
No, I mean... identical to a semaphore?
a semaphore is basically an std::atomic int
Alignant
Anonymous
ya we need them to signal when every camera finishes reading and finding all the points of interest
Ludovic 'Archivist'
And I got rid of them
Ludovic 'Archivist'
or a simple std::atomic_bool to be honest
Ludovic 'Archivist'
using pthread here is just dumb
Alignant
Or a future if you're dumb :D
Ибраги́м
std::condition_variable fits the role
Reason why defining a semaphore was kinda meh-ish
Ибраги́м
Ludovic 'Archivist'
Or a future if you're dumb :D
Or making a continuation type
Anonymous
because each camera is on different threads
Anonymous
so there are 6 threads