03:27
hkaiser has quit [Quit: bye]
11:44
<
pedro_barbosa[m] >
Is there a function to get all the available CUDA devices? I've only found one for the local devices
14:15
hkaiser has joined #ste||ar
14:27
K-ballo has quit [Ping timeout: 272 seconds]
14:52
Yorlik has joined #ste||ar
16:30
<
srinivasyadav227 >
@ped
16:31
<
srinivasyadav227 >
this might help you getting to know the available devices which can be used for CUDA
17:07
bita has joined #ste||ar
17:23
bita has quit [Ping timeout: 265 seconds]
17:29
<
gonidelis[m] >
hkaiser: yt?
17:30
<
gonidelis[m] >
hkaiser: is there any way that i can call `hpx::ranges::remove_if` from `hpx::ranges::remove` ?
17:30
<
gonidelis[m] >
I mean, since they are exposed through `tag_invoke`s
17:38
<
gonidelis[m] >
by using it like `hpx::ranges::remove_if`?
17:39
<
hkaiser >
sure, alternatively invoke the underlying implementation?
17:39
<
gonidelis[m] >
yeah that's an option too
18:46
<
gonidelis[m] >
should our algos overloads work when we invoke them with rvalues?
18:46
<
gonidelis[m] >
for example: `hpx::algo(rvalu1, rvalue2, pred)`
19:13
<
gonidelis[m] >
k-ballo: yt?
19:20
<
k-ballo[m] >
why not?
19:21
<
gonidelis[m] >
k-ballo: i don't know if the iternals could handle it but I am glad to know that they should so
19:21
<
gonidelis[m] >
anyways k-ballo i have this expression `*first++ = std::move(*i);`
19:21
<
gonidelis[m] >
and i get `lvalue required as left operand of assignment
19:22
<
gonidelis[m] >
is this a completely wrong expression in the first place?
19:23
<
gonidelis[m] >
or does the error depend on with what `first` is substituted with?
19:23
<
gonidelis[m] >
on what first is substituted with ^^
19:23
<
k-ballo[m] >
i don't know whether the internals can handle it either
19:23
<
gonidelis[m] >
you suggest that they should though
19:24
<
k-ballo[m] >
unless there's a reason against
19:24
<
gonidelis[m] >
cool
19:24
<
gonidelis[m] >
what about the expression?
19:25
<
k-ballo[m] >
the expression out of context looks ok
19:27
<
gonidelis[m] >
but shouldn't the compiler infer to the substitution if that was what went wrong?
19:27
<
gonidelis[m] >
k-ballo:
19:27
<
k-ballo[m] >
infer what?
19:33
<
gonidelis[m] >
the underlying substitution
19:33
<
gonidelis[m] >
k-ballo:
19:35
<
k-ballo[m] >
i can't parse that sentence
19:35
<
k-ballo[m] >
what do you mean by infer a substitution?
19:35
<
gonidelis[m] >
sorry i meant refer to
19:35
<
gonidelis[m] >
"refer to the underlying substitution"
19:37
<
k-ballo[m] >
what's the underlying substitution?
19:38
<
gonidelis[m] >
k-ballo: in my case it's that
19:38
<
k-ballo[m] >
why would thr compiler refer to that line?
19:38
<
gonidelis[m] >
because this is what `first` is
19:39
<
k-ballo[m] >
that `Iterator` implementation is bogus bte
19:39
<
gonidelis[m] >
k-ballo: what do you mean?
19:39
<
k-ballo[m] >
returns copies on dereference, for starters
19:40
<
k-ballo[m] >
it's not a valid forward iterator
19:41
<
gonidelis[m] >
k-ballo: hm yeah... i thought about it
19:41
<
gonidelis[m] >
but i just can't figure out an iter sent case that is actually based on the standard
19:41
<
gonidelis[m] >
i mean, idk. aren't sentinels supposed to be custom types?
19:43
<
gonidelis[m] >
what's an iter-sent case using actual c++ standard types?
19:44
<
k-ballo[m] >
pointers? begin/end?
19:44
<
gonidelis[m] >
sentinel value ^^
19:45
<
gonidelis[m] >
of the different type
19:45
<
gonidelis[m] >
(i will keep making it all the more complex :P )
19:45
<
k-ballo[m] >
you'd need C++20 for that, so not interesting to you
19:45
<
gonidelis[m] >
extremely interesting to me since i am adapting our algos to c++20 ;p
19:46
<
k-ballo[m] >
we're not going to be requiring C++20 any time soon
19:46
<
k-ballo[m] >
so you won't br getting your test sentinels.from the standard library, make your own
19:46
<
gonidelis[m] >
why the hell do we adapt the algos then?
19:46
<
gonidelis[m] >
for like 9 months now
19:47
<
gonidelis[m] >
k-ballo: ohh... ok
19:47
<
gonidelis[m] >
k-ballo: thank you
19:47
<
gonidelis[m] >
k-ballo: so usin iter - sent is "using my own"
19:47
<
k-ballo[m] >
the standard library isn't the only source of sentinels in the world, people can write their own too
19:48
<
gonidelis[m] >
k-ballo: like we have done with `iter-sent`
19:48
<
gonidelis[m] >
`iter_sent.hpp` ^^
19:48
<
k-ballo[m] >
the iter implementation in that file is bogus, didn't check the sentinel
19:49
<
k-ballo[m] >
you don't need custom iterators anyhow, just sentinels
19:49
<
gonidelis[m] >
k-ballo: you mean i can creat custom sentinels to the standard iterator types
19:49
<
k-ballo[m] >
for any iterator type
19:50
<
gonidelis[m] >
k-ballo: and for the sentinel to be proper it should just conform to the `sentinel_for` constraints
19:51
<
gonidelis[m] >
to the constraints included in the `sentinel_for` c++20 concept i mean
19:51
<
k-ballo[m] >
it needs to br comparable to the iterator, and possibly copyable or even regular too
19:51
<
gonidelis[m] >
hm... sounds straightforward
19:52
<
k-ballo[m] >
should be, just define one op== and then 3 more eq.ops as boilerplate
19:53
<
gonidelis[m] >
and this should be aimed to just FwdIters for example?
19:56
<
gonidelis[m] >
i am asking
19:57
<
gonidelis[m] >
maybe it could work for many types actually. you are right
19:57
<
k-ballo[m] >
for any iterator, probably
19:57
<
gonidelis[m] >
it's peculiar that we don't have already sth like that
20:02
<
k-ballo[m] >
replace all the stuff currently in iter_sent
20:03
<
gonidelis[m] >
ok i will
20:03
<
gonidelis[m] >
thanks
20:04
<
k-ballo[m] >
maybe do that separately
20:05
<
k-ballo[m] >
mhh, it's trivial enough.. drop Iterator, add eq.ops to Sentinel
20:13
<
gonidelis[m] >
4 eq.ops. right?
20:14
<
k-ballo[m] >
yes, three of those written in term of the other
20:15
<
k-ballo[m] >
(note those can't be members)
20:20
<
gonidelis[m] >
k-ballo: why?
20:21
<
k-ballo[m] >
try it and tell me
20:21
<
gonidelis[m] >
k-ballo: ok
20:21
<
gonidelis[m] >
k-ballo: 4 eq ops is because i need all the rvalue - lvalue combination cases?
20:22
<
k-ballo[m] >
no, const-ref should cover all reasonable comparisons
20:22
<
k-ballo[m] >
two == and two !=
20:24
<
gonidelis[m] >
oh ok i got it.
20:24
<
gonidelis[m] >
it's two because it's iter==sent and sent==iter
20:24
<
gonidelis[m] >
cool
20:24
<
gonidelis[m] >
but if they are not member where would they be defined
20:25
<
k-ballo[m] >
how could both of those be members?
20:26
<
gonidelis[m] >
you mean we do not have iter defined within the sent type
20:26
<
k-ballo[m] >
i mean, member functions are either static or have an implicit first parameter
20:27
<
k-ballo[m] >
neither works for iter==sent
20:27
<
k-ballo[m] >
so you need free functions, be it in-line friends or just "global"
20:28
<
k-ballo[m] >
see if you can find meyer's item on heterogeneous comparisons
20:30
<
gonidelis[m] >
ok i have things to explore then. thanks a lot
20:38
Yorlik has quit [Quit: Leaving]
21:45
bita has joined #ste||ar
22:01
bita has quit [Ping timeout: 246 seconds]
22:40
K-ballo has joined #ste||ar