Follow us on Google+ Follow us on Facebook Follow us on Twitter

Opened 7 years ago

Last modified 6 years ago

#246 new enhancement

Make working directory a per-thread property

Reported by: Jiri Svoboda Owned by:
Priority: minor Milestone:
Component: helenos/lib/c Version: mainline
Keywords: Cc:
Blocker for: Depends on:
See also:


Currently the working directory is a property of the task as a whole (same as in POSIX). This is incompatible with multi-threaded applications.

I propose to change WD to be a thread(fibril)-local property.

Compatibility analysis: This will not affect single-threaded POSIX applications. This could only break multi-threaded POSIX applications that rely on setting WD in one thread and then accessing it in another. It could be fixed in the prospective POSIX compatibility layer, however.

Change History (6)

comment:1 Changed 7 years ago by Jakub Jermář

I am concerned about the possible complications this could cause given the way we use kernel threads - i.e. as execution units for fibrils.

comment:2 Changed 7 years ago by Jakub Jermář


comment:3 Changed 7 years ago by Jiri Svoboda

I don't quite follow. Can you elaborate on this and perhaps give an example?

comment:4 Changed 7 years ago by Jakub Jermář

This was a reaction to making it a per-thread property. As fibrils can move among threads, their cwd would change accordingly. If it was a per-fibril property, I don't see any problem.

comment:5 Changed 7 years ago by Jakub Jermář

Type: proposalenhancement

comment:6 Changed 6 years ago by Jakub Jermář

Milestone: 0.5.0
Note: See TracTickets for help on using tickets.