<gnikunj[m]>
error: too few arguments to function call, expected 2, have 1
<gnikunj[m]>
return F(std::forward<Ts>(vs)...);
<hkaiser>
ok, ok - I'll try it to compile myself ;-)
<gnikunj[m]>
hkaiser: please let me know if you're able to make it work
<gnikunj[m]>
btw, is it possible to decay an action back to function?
<hkaiser>
try again
<hkaiser>
that's what the invoker is doing, it calls invoke()
<gnikunj[m]>
hkaiser: it works!
<gnikunj[m]>
and it interrupts correctly as welll!
<gnikunj[m]>
I think I can make replicate apis work with interrupts using this technique. Thanks a lot!
<hkaiser>
cool
<gnikunj[m]>
btw can you explain me the arguments of invoke?
<hkaiser>
doesn't work with component actions, though - for that you need the real address, etc.
<gnikunj[m]>
what does the 0,0 mean really?
<hkaiser>
first argument should be the local virtual address of the target (for components it's their address, for plain actions it's ignore, so we use zero)
<hkaiser>
the second argument represents the component type which is zero for plain actions as well
<gonidelis[m]>
There is `constexpr operator in_out_result<I2, O2>() const & ` and ` constexpr operator in_out_result<I2, O2>() && `
<gonidelis[m]>
Is it sth like, what the operator returns??
<gonidelis[m]>
(I fully understand the difference between `const &` and `&&` but I just don't know why are they placed there and what is their purpose in this context. I reckon it's sth like a return type.)
Yorlik has joined #ste||ar
Yorlik has quit [Ping timeout: 256 seconds]
teonnik has joined #ste||ar
<zao>
A member like `operator T()` is like a member function `T convert_to()` which the compiler considers when the programmer uses the object in a place where a type conversion is needed.
<zao>
Conceptually, a member function `T S::f()` is much like a free function `T f(S* this)`, that is, there's an implied `this` parameter with type `S const* const` or `S* const`.
<zao>
If you on a member function suffix the declaration with `const`, the implied `this` points to a const object.
<zao>
If you have member functions `T f() const` and `T f()`, they form an overload set analogous to `T f(S*)` and `T f(S const*)`, where the overload is selected based on the constness of the object you call it with.
<zao>
When you have ref-qualified member functions, where you suffix the declaration with `&` and `&&`, this introduces additional overloads to the overload set, but instead of deciding based on constness of the object you call with, they are chosen based on the lvalue/rvalue-ness of the object.
<zao>
In the case of the thing you linked, there's a desire to overload based on whether the object it's called on is a rvalue or not, to be able to move from the source object when doing a conversion.
<zao>
The ref-qualifiers only serve to distinguish what kind of object the overload is valid for, they don't affect the return type nor the type of `this`.
<zao>
gonidelis[m]: Does this clarify anything?
K-ballo1 has joined #ste||ar
diehlpk_work has quit [Remote host closed the connection]
diehlpk_work has joined #ste||ar
K-ballo has quit [Ping timeout: 240 seconds]
K-ballo1 is now known as K-ballo
ct-clmsn has joined #ste||ar
ct_ has joined #ste||ar
ct-clmsn is now known as Guest46679
Guest46679 has left #ste||ar [#ste||ar]
ct_ has quit [Client Quit]
ct_ has joined #ste||ar
ct_ is now known as ct_clmsn
<gonidelis[m]>
zao: oh ok, so it's sth like `constexpr operator in_out_result<I2, O2>() ( const S& x)`?
<gonidelis[m]>
Nevertheless I think I get it... it's sth like when we create template overloads of the same function and the compiler chooses the best fit when function is called according to the arguments (maybe)
<zao>
It selects the overload based on the object in a similar way that overloads are selected based on regular arguments, yes.
<gonidelis[m]>
hmmmm great!!!
<gonidelis[m]>
So this particular in_out_result just takes two l-values and returns 2 l-values
<gonidelis[m]>
or it just takes two r-values and returns two r-values
<gonidelis[m]>
is that right?
<zao>
Prior to ref-qualifiers, you could only overload member functions based on object constness. With ref-qualifiers, you can also overload on rvalueness.
<zao>
A conversion operator converts from one object type to another object type. In this case, the conversion operator does this by individually converting each member into the corresponding member of the target.
<zao>
So you can say `io_res<X, Y> src; io_res<Z, W> dst = src;` as long as `Z` converts from `X` and `W` converts from `Y`.
<zao>
The ref-qualifiers lets you have different overloads for that sequence and for `io_res<Z, W> dst = std::move(src);` or a temporary `io_res`.
<gonidelis[m]>
zao: So what ref-qualifiers do is help us select the proper overload according to the callable object?
<zao>
There's nothing callable here, it's a conversion operator, but yes, it's selecting an overload based on the source.
<K-ballo>
gonidelis[m]: are you familiar with how a `void fun(X const&); void fun(X&&);` overload behaves?
<gonidelis[m]>
zao: yeah yeah sorry you are right
<gonidelis[m]>
K-ballo: Sorry I was reading your previous message... need to look out what `convert_to()` does. As for the const-ref and rvalue-ref overloads I think I do know what they do
<zao>
It's a made-up name for illustration.
<gonidelis[m]>
The first overload is picked when we pass an lvalue (the usual case) while the second one is picked when we pass sth movable (i think)
<K-ballo>
the first is for lvalues, the second one for rvalues
<gonidelis[m]>
I tried not using these trivial words in order to show you that I know what an lvalue and an rvalue mean but yes
<K-ballo>
movable is a property of a type, it's orthogonal to value category
<K-ballo>
value category (lvalue, rvalue, ...) is a property of expressions
<gonidelis[m]>
Actually I just refreshed mr.hkaise's lectures which are a piece of art on that subject so I do understand the difference ( K-ballo your name was brought up quite often ;p). I just didn't know about ref-qualifiers yet... Let me iterate over your messages again
<K-ballo>
so you know how a member function `void X::fun()` has an implicit this argument, the object in which the member is called
<gonidelis[m]>
K-ballo: isn't that rvalues "are moving" while lvalues "are copied" in the general cases?
<K-ballo>
one normally wants to move from rvalues, because they won't be used anymore, and copy from lvalues since others are still looking at it
<gonidelis[m]>
zao: So basically this `i_o_res()` is the process of convertig a tuple (of arbitrary types) to a tuple of another arbitrary types???
<zao>
The conversion operator provides that ability, yes.
<zao>
As for the overall purpose of these tuples, they seem to be used for the return type of assorted algorithms. Those would be usable on their own, but the conversion operator allows them to be used in more generic contexts where you need a similar type (like chaining range operations?) as they can convert easily.
<hkaiser>
just wanted to ask you to wait with merging the cpo PRs
<hkaiser>
I'm planning to add more tests first
<ms[m]>
sure, not a problem at all
<hkaiser>
the new non-policy overloads have no tests yet
<ms[m]>
did I merge that one too early?
<hkaiser>
no problem, I can add tests still ;-)
<ms[m]>
ah, yep
<hkaiser>
those don't have to go into 1.5, so I think we don't have to rush it
<ms[m]>
yeah, anytime they're ready
<hkaiser>
ok, thanks
<ms[m]>
you can merge them as soon or as late as you feel like merging them, I don't think they're very controversial, especially since you've done quite a few of them now ;)
<hkaiser>
ok, will do
<ms[m]>
as long as they don't break ci (more than it is now...)
<ms[m]>
also, please don't stop making prs, I hope you have nothing else planned for august ;)
teonnik has left #ste||ar ["User left"]
<ms[m]>
welcome teonnik!
ct_clmsn has quit [Quit: Leaving]
nanmiao11 has joined #ste||ar
<hkaiser>
ms[m]: heh, I wish
<hkaiser>
have to catch up on real work for a change ;-)
diehlpk_work has quit [Changing host]
diehlpk_work has joined #ste||ar
bita_ has joined #ste||ar
<gonidelis[m]>
hkaiser: hey
<hkaiser>
gonidelis[m]: hey
<gonidelis[m]>
just wanted to ask: do I need to provide tests for in_in_out_result?
<hkaiser>
don't think so
<hkaiser>
I didn't provide any for in_out_result ;-)
<gonidelis[m]>
ok and sth more important
<gonidelis[m]>
I saw that you created that `get_in_out_result`
<hkaiser>
yes
<gonidelis[m]>
Could you remind me what is that doing?
<gonidelis[m]>
Is it like, it takes an iterator that works over tuples and just desolves it in the two elements?
akheir has joined #ste||ar
<hkaiser>
gonidelis[m]: it turns the tuple which is returned from the for_each_partitioner into an in_out_result or a future<tuple<>> into a future<in_out_result> (for task policies)
<gonidelis[m]>
hkaiser: is it used for the segmented algorithms?
<hkaiser>
no
<hkaiser>
it's used for the normal iterators as well
<gonidelis[m]>
ok I don't really know what is the `for_each_partitioner` :/
<gonidelis[m]>
hkaiser: Do I need to create a `get_in_in_out_result` too?
<hkaiser>
gonidelis[m]: not sure, you'll see
diehlpk has joined #ste||ar
<gonidelis[m]>
hkaiser: ok :)
<gonidelis[m]>
is it me, or rostams ia little bit heavy today?
<hkaiser>
gonidelis[m]: we use it for HPX unit testing now ;-)
<gonidelis[m]>
aahh ok... I have `salloc -p marvin`
<gonidelis[m]>
Does that interfere with your job
<gonidelis[m]>
?
<hkaiser>
no
<gonidelis[m]>
hmm... ok
<hkaiser>
the tests will use low priority, so your jobs are more important
<gonidelis[m]>
I just `make -j tests` and it hangs for some reason
<hkaiser>
hmmm
<hkaiser>
talk to akheir, he's the master of rostam
<gonidelis[m]>
while i am on marvin
<hkaiser>
if you have access to the node nobody should interfere
<gonidelis[m]>
oke
Yorlik has joined #ste||ar
diehlpk has quit [Ping timeout: 260 seconds]
Yorlik has quit [Ping timeout: 240 seconds]
Yorlik has joined #ste||ar
<akheir>
gonidelis[m]: hey I am looking at rostam. there is no particular problem but you are the second person to complain about its speed
<akheir>
gonidelis[m]: when you said hang was is a crash to slow response? for how long?
<gonidelis[m]>
akheir: yeah... it's like I am doing `git status` and it takes like 40 seconds in order to give me output
<gonidelis[m]>
plus, I tried running `srun -p marvin -N 1 -t 1:00:00 --pty /bin/bash -l` and I just had to wait for more than a minute without response, so I `ctrl+c`ed and stopped trying. My internet connection is fine (like 30 mbps as usual)
<akheir>
gonidelis[m]: yeah there is much larger and usual load in storage server. I won't name who but he knows that ;-)
<akheir>
the job will finish in 2 hours
<gonidelis[m]>
akheir: aren't the jenkins tests responsible for that?
<akheir>
No, Jenkins doesn't right that much. write now to write I/O load is about 760MiB/s
<akheir>
Jenkins jobs are compile and usually cpu-bound jobs
<ms[m]>
akheir: btw, if needed we can definitely de-prioritize the jenkins jobs, interactive jobs should have priority, just let me know
<hkaiser>
ms[m]: yah, we talked about that with akheir today
<akheir>
ms[m]: yeah. I will create priority queue for other users
neill[m] has joined #ste||ar
kale[m] has quit [Ping timeout: 264 seconds]
kale[m] has joined #ste||ar
<hkaiser>
akheir: thanks a lot!
<ms[m]>
ok, also works, thanks :) in any case, if changes are needed to the jenkins jobs just ping me
<akheir>
ms[m]: the problem I see with Jenkins is that the setting on in repo itself and any change requires a PR, right? this makes tweaking a bit difficult
<ms[m]>
it has it's good and bad sides :) but it definitely makes applying changes a bit slower
<ms[m]>
changes like that can go in pretty quickly though (I admit to having pushed a few times directly to master to make changes to the configuration lately)
<ms[m]>
the configuration could live outside of the repo as well if it turns out to be more convenient
<akheir>
yeah, I've thought about that. but let's keep thing simple for now
carola[m]1 has joined #ste||ar
<parsa>
how is one supposed to use std::transform with more than two input ranges?
<parsa>
without boost::combine that is
<K-ballo>
one's not
<parsa>
:'''''(
<parsa>
K-ballo: does that mean we say no to no-raw-loops?
nanmiao11 has quit [Remote host closed the connection]
nanmiao11 has joined #ste||ar
<hkaiser>
parsa: zip_iterator?
<parsa>
thanks! that works. is there anything reasonable i can do if i'm restricted to the standard library?