On 9/14/21 9:56 AM, eugene wrote:
> On Tuesday, 14 September 2021 at 16:43:50 UTC, jfondren wrote:
>> The misaligned pointer and the
>> reference-containing struct that vanishes on the return of your
>> corresponding function are both problems for this.
>
> where did you find 'misaligned
On Tuesday, 14 September 2021 at 18:33:33 UTC, Steven
Schveighoffer wrote:
People are trying to help you here.
Then, answer the questions.
Why those sg0 and sg1 are 'collected'
by this so f... antstic GC?
On 9/14/21 2:05 PM, eugene wrote:
On Tuesday, 14 September 2021 at 17:02:32 UTC, jfondren wrote:
It doesn't seem like communication between us is possible
and you are wrong, as usual ,)
in the "a five-pound phone won't sell" way.
I am not a 'selling boy'
My suggestion remains: try
On Tuesday, 14 September 2021 at 17:02:32 UTC, jfondren wrote:
It doesn't seem like communication between us is possible
and you are wrong, as usual ,)
in the "a five-pound phone won't sell" way.
I am not a 'selling boy'
My suggestion remains: try troubleshooting by making your
program
On Mon, Sep 13, 2021 at 06:19:20PM +, NonNull via Digitalmars-d-learn wrote:
> On Monday, 13 September 2021 at 16:12:34 UTC, H. S. Teoh wrote:
> > On Mon, Sep 13, 2021 at 02:12:36PM +, NonNull via
> > Digitalmars-d-learn wrote:
> > > Which operators cannot be overloaded and why not?
> >
>
On Tuesday, 14 September 2021 at 16:56:52 UTC, eugene wrote:
On Tuesday, 14 September 2021 at 16:43:50 UTC, jfondren wrote:
GC needs to be able to stop your program
nice fantasies...
and find all of the live objects in it. The misaligned pointer
and the reference-containing struct that
On Tuesday, 14 September 2021 at 16:43:50 UTC, jfondren wrote:
GC needs to be able to stop your program
nice fantasies...
and find all of the live objects in it. The misaligned pointer
and the reference-containing struct that vanishes on the return
of your corresponding function are both
On Tuesday, 14 September 2021 at 16:15:20 UTC, eugene wrote:
On Tuesday, 14 September 2021 at 16:07:00 UTC, jfondren wrote:
No. And when was the first one?
here:
On Monday, 13 September 2021 at 18:45:22 UTC, jfondren wrote:
auto p = cast(EpollEvent*) pureMalloc(EpollEvent.sizeof);
What?
On Tuesday, 14 September 2021 at 16:07:00 UTC, jfondren wrote:
No. And when was the first one?
here:
On Monday, 13 September 2021 at 18:45:22 UTC, jfondren wrote:
auto p = cast(EpollEvent*) pureMalloc(EpollEvent.sizeof);
What? Allocate struct epoll_event on the heap?
It is a feeble joke
On Tuesday, 14 September 2021 at 15:37:27 UTC, eugene wrote:
On Tuesday, 14 September 2021 at 14:56:00 UTC, jfondren wrote:
You could fix this by having a 128-bit struct and passing C an
index into it
It is another "not so funny joke", isn't it?
No. And when was the first one?
```d
align
On 9/14/21 10:56 AM, jfondren wrote:
On Tuesday, 14 September 2021 at 14:40:55 UTC, eugene wrote:
On Tuesday, 14 September 2021 at 12:09:03 UTC, Steven Schveighoffer
wrote:
This project is too big and complex
Really, "too big and complex"?
It's as simple as a tabouret :)
It's just a
On Tuesday, 14 September 2021 at 14:56:00 UTC, jfondren wrote:
You could fix this by having a 128-bit struct and passing C an
index into it
It is another "not so funny joke", isn't it?
Look
```c
typedef union epoll_data {
void *ptr;
int fd;
uint32_t u32;
On Tuesday, 14 September 2021 at 12:09:03 UTC, Steven
Schveighoffer wrote:
This project is too big and complex for me to diagnose by just
reading, it would take some effort
take a look at
On Tuesday, 14 September 2021 at 14:40:55 UTC, eugene wrote:
On Tuesday, 14 September 2021 at 12:09:03 UTC, Steven
Schveighoffer wrote:
This project is too big and complex
Really, "too big and complex"?
It's as simple as a tabouret :)
It's just a toy/hobby 'project'.
A 5-pound phone isn't
On Tuesday, 14 September 2021 at 12:09:03 UTC, Steven
Schveighoffer wrote:
This project is too big and complex
Really, "too big and complex"?
It's as simple as a tabouret :)
It's just a toy/hobby 'project'.
On Tuesday, 14 September 2021 at 12:52:44 UTC, Steven
Schveighoffer wrote:
But I agree that a superficial reading of your code seems like
it ought to not be collected, and that problem is also worth
figuring out. I have high confidence that it's probably not a
design flaw in the GC, but rather
On Tuesday, 14 September 2021 at 12:53:27 UTC, Adam D Ruppe wrote:
I had a problem just like this before because I was sending
objects through the pipe. And while they were in the pipe -
```rust
pub fn msg(, code: u32) {
let ptr: *const u32 =
let n = unsafe {
On Tuesday, 14 September 2021 at 12:53:27 UTC, Adam D Ruppe wrote:
I had a problem just like this before because I was sending
objects through the pipe.
This reminds my (not very successfull) attempts to implement the
idea in Rust:
```rust
pub struct Edsm {
name: String,
pub
On Tuesday, 14 September 2021 at 12:42:51 UTC, eugene wrote:
I understand your idea, but even if this will help, the question
remains - why that particular object is so special for GC.
I had a problem just like this before because I was sending
objects through the pipe. And while they were in
On 9/14/21 8:42 AM, eugene wrote:
On Tuesday, 14 September 2021 at 12:09:03 UTC, Steven Schveighoffer wrote:
I still recommend pinning the object when adding the epoll event and
seeing if that helps.
I understand your idea, but even if this will help, the question
remains - why that
On Tuesday, 14 September 2021 at 12:13:15 UTC, Steven
Schveighoffer wrote:
On 9/14/21 7:31 AM, eugene wrote:
On Monday, 13 September 2021 at 17:18:30 UTC, eugene wrote:
EventSource s = events[k].es;
ulong ecode = s.eventCode(events[k].event_mask);
// < SIGSEGV
On Tuesday, 14 September 2021 at 12:09:03 UTC, Steven
Schveighoffer wrote:
Though as I have learned helping C converts before, most of the
time things like this have to do with forgetting to store a GC
reference somewhere.
Yeah, in my first version I had
```d
foreach (k; 0 ..
On 9/13/21 10:43 PM, Chris Piker wrote:
Hi D
I just finished a ~1K line project using `dxml` as the XML reader for my
data streams. It works well in my test examples using memory mapped
files, but like an impulse shopper I didn't notice that dxml requires
`ForwardRange` objects. That's
On 9/14/21 7:31 AM, eugene wrote:
On Monday, 13 September 2021 at 17:18:30 UTC, eugene wrote:
Then after pressing ^C (SIGINT) the program gets SIGSEGV, since
references to sg0 and sg1 are no longer valid (they are "sitting" in
epoll_event structure).
... forget to mention, crashes here:
On 9/14/21 1:49 AM, Tejas wrote:
On Monday, 13 September 2021 at 18:42:47 UTC, Steven Schveighoffer wrote:
On 9/13/21 1:54 PM, eugene wrote:
[...]
The GC only scans things that it knows about.
Inside your EventQueue you have this code:
[...]
Umm is it okay that he declared variables
On Monday, 13 September 2021 at 17:18:30 UTC, eugene wrote:
Then after pressing ^C (SIGINT) the program gets SIGSEGV, since
references to sg0 and sg1 are no longer valid (they are
"sitting" in epoll_event structure).
... forget to mention, crashes here:
```d
bool wait() {
const
On Monday, 13 September 2021 at 18:45:22 UTC, jfondren wrote:
```d
auto p = cast(EpollEvent*)
pureMalloc(EpollEvent.sizeof);
```
What? Allocate struct epoll_event on the heap?
It is a feeble joke ;)
```c
static int ecap__add(int fd, void *dptr)
{
struct epoll_event waitfor =
On Tuesday, 14 September 2021 at 05:49:58 UTC, Tejas wrote:
Umm is it okay that he declared variables `init` and `idle` of
type `Stage` inside the constructor?
States of a machine are in associative array.
All other machines create their states in constructor,
local variables are for using
On Tuesday, 14 September 2021 at 05:06:01 UTC, Elronnd wrote:
On Tuesday, 14 September 2021 at 03:24:45 UTC, max haughton
wrote:
On Tuesday, 14 September 2021 at 03:19:46 UTC, Elronnd wrote:
On Monday, 13 September 2021 at 11:40:10 UTC, max haughton
wrote:
The dragon book barely mentions SSA
29 matches
Mail list logo