Modify

Ticket #2637 (closed Feature Requests: fixed)

Opened 5 years ago

Last modified 23 months ago

Request for shared_mutex duration timed_lock and timed_lock_shared

Reported by: mur@… Owned by: viboes
Milestone: Boost 1.50.0 Component: thread
Version: Boost 1.37.0 Severity: Optimization
Keywords: shared mutex duration Cc:

Description (last modified by viboes) (diff)

The following should be added

    template<typename TimeDuration>
    bool shared_mutex::timed_lock_shared(TimeDuration const & relative_time);
    template<typename TimeDuration>
    bool shared_mutex::timed_lock(TimeDuration const & relative_time);

Attachments

Change History

comment:1 Changed 5 years ago by mur@…

  • Owner set to anthonyw
  • Type changed from Bugs to Feature Requests
  • Component changed from None to thread
  • Severity changed from Problem to Optimization

comment:2 Changed 2 years ago by viboes

  • Owner changed from anthonyw to viboes
  • Status changed from new to assigned

comment:3 Changed 2 years ago by viboes

  • Description modified (diff)
  • Summary changed from shared mutex lock to Request for shared_mutex duration timed_lock and timed_lock_shared

comment:4 follow-up: ↓ 6 Changed 2 years ago by viboes

These functions are already committed. Only the documentation is missing and I will deprecated them once I include the try_lock_for and try_lock_shared_for functions having as parameter a chrono::duration parameter.

    template <class Rep, class Period>
        bool try_lock_for(const std::chrono::duration<Rep, Period>& rel_time);
    template <class Clock, class Duration>
        bool
        try_lock_until(
                      const std::chrono::time_point<Clock, Duration>& abs_time);

    template <class Rep, class Period>
        bool
        try_lock_shared_for(const std::chrono::duration<Rep, Period>& rel_time);
    template <class Clock, class Duration>
        bool
        try_lock_shared_until(
                      const std::chrono::time_point<Clock, Duration>& abs_time);

Would this respond to your request once the chrono based interface is released?

comment:5 Changed 2 years ago by viboes

  • Milestone changed from Boost 1.38.0 to Boost 1.50.0

comment:6 in reply to: ↑ 4 Changed 2 years ago by mur@…

Would this respond to your request once the chrono based interface is released?

Yes.

Will there be the absolute time used internally? What happens if the system clock is altered in between?

comment:7 Changed 23 months ago by viboes

  • Status changed from assigned to closed
  • Resolution set to fixed

Committed in release branch at [78543]

View

Add a comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
The resolution will be deleted. Next status will be 'reopened'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.