profile
viewpoint
Tim Diekmann TimDiekmann Bielefeld, Germany

rust-lang/wg-allocators 104

Home of the Allocators working group: Paving a path for a standard set of allocator traits to be used in collections!

TimDiekmann/alloc-compose 22

Composable allocator structures for plugging together more powerful allocators

TimDiekmann/alloc-wg 15

Attempt of collection several proposals of the allocators-wg

TimDiekmann/concourse 0

Concourse is a container-based continuous thing-doer written in Go and Elm.

TimDiekmann/dex 0

A fork of coreos/dex with changes necessary for Concourse. **See `maintenance` branch for details.**

TimDiekmann/dlmalloc-rs 0

dlmalloc ported into Rust

TimDiekmann/highfive 0

Github hooks to provide an encouraging atmosphere for new contributors

TimDiekmann/miri 0

An interpreter for Rust's mid-level intermediate representation

TimDiekmann/nomicon 0

The Dark Arts of Advanced and Unsafe Rust Programming

TimDiekmann/onedark.vim 0

A dark Vim/Neovim color scheme inspired by Atom's One Dark syntax theme.

issue commentrust-lang/wg-allocators

Tracking Issue for structs which needs an allocator

Forwarding to hashbrown should be pretty straightforward. Currently, Vec is queued for a crater run and this will take a while. I can take a look at HashMap (+ HashSet, which is basically the same) afterwards. Thanks for the heads up!

TimDiekmann

comment created time in 15 hours

create barnchTimDiekmann/rust

branch : vec-alloc

created branch time in 2 days

pull request commentrust-lang/rust

Add support for custom allocators in `Vec`

@rustbot modify labels: +A-allocators +T-libs

TimDiekmann

comment created time in 2 days

PR opened rust-lang/rust

Add support for custom allocators in `Vec`

r? @Amanieu

This pull request requires a crater run.

Prior work:

+496 -200

0 comment

10 changed files

pr created time in 2 days

pull request commentrust-lang/rust

fix Box::into_unique

Thanks for fixing this! :)

RalfJung

comment created time in 3 days

issue commentrust-lang/wg-allocators

Tracking Issue for structs which needs an allocator

rust-lang/rust#77187 just got merged. I'll add an allocator parameter to Vec next.

TimDiekmann

comment created time in 3 days

issue closedrust-lang/wg-allocators

Compat of adding parameters to stable types

Are there backward-compatibility issues with adding a defaulted type parameter to a stable type? For example changing:

struct Vec<T> {…}

To:

struct Vec<T, A: Alloc = Global> {…}

The API Evolution RFC claims this is not a major breaking change, but I vaguely recall discussion of type inference being negatively affected.

Is https://github.com/rust-lang/rust/issues/27336 relevant here?

closed time in 3 days

SimonSapin

issue commentrust-lang/wg-allocators

Compat of adding parameters to stable types

We tested this with rust-lang/rust#71873 and rust-lang/rust#77187.

SimonSapin

comment created time in 3 days

pull request commentrust-lang/rust

Associate an allocator to boxes

In case anyone subscribed here and want an update: #77187 just got merged :rocket:

glandium

comment created time in 3 days

delete branch TimDiekmann/rust

delete branch : box-alloc

delete time in 3 days

pull request commentrust-lang/rust

Support custom allocators in `Box`

@rustbot ping infra

The merged succeeded, but a CI job failed. I don't know, what the job is about, but the fail is unrelated to this PR.

TimDiekmann

comment created time in 3 days

pull request commentrust-lang/rust

Support custom allocators in `Box`

Maybe rollup=never should be applied to keep track of small performance changes.

TimDiekmann

comment created time in 5 days

pull request commentrust-lang/rust

Support custom allocators in `Box`

Applied #78208

@rustbot modify labels: +S-waiting-on-review -S-waiting-on-author

TimDiekmann

comment created time in 5 days

push eventTimDiekmann/rust

Mark Rousskov

commit sha e023158145ece18176a2e93420600ccda0d0bc58

Permit uninhabited enums to cast into ints This essentially reverts part of #6204.

view details

Mark Rousskov

commit sha 990a39596cf3b33e550f2045f78a62970f8d78f8

Prevent ICE on uninhabited MIR interpretation

view details

Mark Rousskov

commit sha 05c9c0ee5dcd935f518db151bee2dc88380fb92f

Modify executable checking to be more universal This uses a dummy file to check if the filesystem being used supports the executable bit in general.

view details

dylni

commit sha 1ff7da6551a7cdf6ace2a9d00e92bbab550334ee

Move `slice::check_range` to `RangeBounds`

view details

dylni

commit sha 1095dcab96d524e700b11edf366d45a0fd173fa0

Fix links

view details

dylni

commit sha eb63168e007058dad4af758faf1dca449c049777

Fix doctests

view details

dylni

commit sha f055b0bb0847ecf08fe452a270faae8324b55b05

Rename method to `assert_len`

view details

Bastian Kauschke

commit sha fd22e87afc9082522bc7b52e32d25d43c64594e6

fix flag computation for `ExistentialPredicate::Projection`

view details

Bastian Kauschke

commit sha 7652b4b1d9cec0ad22f529a4335d05f7d7792521

guard against `skip_binder` errors during FlagComputation

view details

rail

commit sha dc89bb1135afc31fc9ee2272e627192c04354d22

Use if_chain in Increment/InitializeVisitor

view details

rail

commit sha 116f30dc33d9e3744f257f2f7f5467acfbff178b

Use else blocks instead of return statements in Increment/InitializeVisitor

view details

rail

commit sha b2d5b89a1de15df9052fdf44d01b174add82837f

Check if it's after the loop earlier

view details

rail

commit sha 31cb1109648bf4242cab47571343578244e7fb9d

add concinient methods to Increment/InitializeVisitor

view details

rail

commit sha c599e2fcfaaedb12b560f4136bab3d0b450acf8f

Split VarState

view details

rail

commit sha 13c207d3756754c54a6b20d852087616d5abfbf4

Generalise `InitializeVisitor`

view details

rail

commit sha 9573a0d378033a81e55ca834a5d305d3cf2be24d

Rename variables

view details

rail

commit sha 1026b42f0694eb9239b5cebe80be743d5ded0da5

Rename a struct and variables

view details

rail

commit sha b4b4da162f19e9a4c63854a2b5a6167b83f9d8b9

Introduce Start and StartKind

view details

rail

commit sha 720f19f2ec4282f636889b35beabf31272e3b1b2

Implement detecting `manual_memcpy` with loop counters

view details

rail

commit sha de56279cd9047832216e1d1c06dc45375bf01b31

Implement building the `manual_memcpy` sugggestion with loop counters

view details

push time in 5 days

startedrust-lang/wg-cargo-std-aware

started time in 5 days

Pull request review commentrust-lang/rust

Support custom allocators in `Box`

 impl<T: ?Sized> Box<T> {     )]     #[inline]     #[doc(hidden)]-    pub fn into_unique(b: Box<T>) -> Unique<T> {+    pub fn into_unique(b: Self) -> (Unique<T>, A) {         // Box is recognized as a "unique pointer" by Stacked Borrows, but internally it is a         // raw pointer for the type system. Turning it directly into a raw pointer would not be         // recognized as "releasing" the unique pointer to permit aliased raw accesses,-        // so all raw pointer methods go through `leak` which creates a (unique)-        // mutable reference. Turning *that* to a raw pointer behaves correctly.-        Box::leak(b).into()+        // so all raw pointer methods have to leak the box. Turning *that* to a raw pointer+        // behaves correctly.+        let b = mem::ManuallyDrop::new(b);++        // The box is unitiliazed later when moving out the allocator. The pointer is stored+        // beforehand.+        let ptr = b.0;+        let alloc = unsafe { ptr::read(&b.1) };+        (ptr, alloc)+    }++    /// Returns a reference to the underlying allocator.+    ///+    /// Note: this is an associated function, which means that you have+    /// to call it as `Box::alloc_ref(&b)` instead of `b.alloc_ref()`. This+    /// is so that there is no conflict with a method on the inner type.+    #[unstable(feature = "allocator_api", issue = "32838")]+    #[inline]+    pub fn alloc_ref(b: &Self) -> &A {

I'm fine with both, I just picked alloc_ref because of the trait name. Maybe we should discuss (in the WG), if we should rename AllocRef to Allocator and alloc to allocate.

TimDiekmann

comment created time in 6 days

PullRequestReviewEvent

push eventTimDiekmann/rust

Tim Diekmann

commit sha 693a2bf18b7090202784f561de3dfca45c4f79be

Rename `Box::alloc` to `Box::alloc_ref`

view details

push time in 6 days

pull request commentrust-lang/rust

Support custom allocators in `Box`

@Amanieu What do you think how should we proceed? Keep into_raw in Box<T, A> or move it back to Box<T, Global>? If we'd go with the latter, leak should also be moved back.

TimDiekmann

comment created time in 13 days

issue openedrust-lang/rust

Bors did not report a merge conflict

#77981 has made three very small changes, one of those made #77187 unmergable. Previously, bors reported, if a pull request got unmergable.

@rustbot modify labels: +T-infra

created time in 14 days

push eventTimDiekmann/rust

Matt Brubeck

commit sha b4b383981abac7ca8aa180c7ae3e28876615b887

Add PartialEq impls for Vec <-> slice

view details

Mateusz Mikuła

commit sha 0ad3da06843089c0bf10d6caa3fbbc72fa67787a

Enable ASLR for windows-gnu

view details

Tim Nielens

commit sha 390a13b06c79d4177b829097b06453e38188081f

needless-lifetime - fix nested elision site FPs

view details

Tim Nielens

commit sha a60e5de90c7370d4fb3e6561d3cb55495cda2e2a

needless-lifetime / nested elision sites / PR remarks

view details

Tim Nielens

commit sha c8e9e52303da6dff4bc5cc4db3021d608fca6c70

needless-lifetime / add test cases for nested elision sites

view details

Takayuki Nakata

commit sha 1778a1ec4615a42a8ba9497006b07859186c08a1

Restrict `same_item_push` to suppress false positives It emits a lint when the pushed item is a literal, a constant and an immutable binding that are initialized with those.

view details

Takayuki Nakata

commit sha 0117ea2b016133145f9e02e27421ac3672b42f57

Refactoring: use inner function

view details

Takayuki Nakata

commit sha b80576fba633e1fc214c9f6900d7ca3424bda6d0

Some refactoring

view details

Takayuki Nakata

commit sha 14faebe20ea82392f393c3ff5efaab7250e51989

Add some tests to `same_item_push` Add tests in which the variable is initialized with a match expression and function call

view details

Takayuki Nakata

commit sha 2972ad3ef661071531a61ec8999b668a6b734b74

Refactoring: tests in `same_item_push`

view details

Takayuki Nakata

commit sha 730ca457f580247667ed0cd5965bc08752ebc0b3

Address `items_after_statement`

view details

Nathan West

commit sha a02014280586b53997622c501db00398376967a8

Refactor io/buffered.rs into submodules

view details

Nathan West

commit sha 96229f02402e82914ec6100b28ad2cbdd273a0d4

move buffered.rs to mod.rs

view details

Dylan MacKenzie

commit sha 72b402ed38f0c71461038aef8a49a02e49280788

Add pass names to some common dataflow analyses

view details

Nathan West

commit sha 6d75cdfc9ed9e6987bd23add6cf3954d2499dce2

Added updated compiler diagnostic

view details

Amjad Alsharafi

commit sha da700cba08a2b194d19e63d3c51ebadce96fe46b

Stabilize move_ref_pattern

view details

Amjad Alsharafi

commit sha afb9eeb1b9ea16ca65e38673a0ef3e7be81d7252

Disabled error `E0007` from rustc_error_codes

view details

Nathan West

commit sha c4280af8285c61b367a87c8f6eef9876011a8150

Retry fix error reporting suggestions

view details

Aaron Hill

commit sha cfe07cd42a92610219d6ffc1ae5eefef42f5254a

Use llvm::computeLTOCacheKey to determine post-ThinLTO CGU reuse During incremental ThinLTO compilation, we attempt to re-use the optimized (post-ThinLTO) bitcode file for a module if it is 'safe' to do so. Up until now, 'safe' has meant that the set of modules that our current modules imports from/exports to is unchanged from the previous compilation session. See PR #67020 and PR #71131 for more details. However, this turns out be insufficient to guarantee that it's safe to reuse the post-LTO module (i.e. that optimizing the pre-LTO module would produce the same result). When LLVM optimizes a module during ThinLTO, it may look at other information from the 'module index', such as whether a (non-imported!) global variable is used. If this information changes between compilation runs, we may end up re-using an optimized module that (for example) had dead-code elimination run on a function that is now used by another module. Fortunately, LLVM implements its own ThinLTO module cache, which is used when ThinLTO is performed by a linker plugin (e.g. when clang is used to compile a C proect). Using this cache directly would require extensive refactoring of our code - but fortunately for us, LLVM provides a function that does exactly what we need. The function `llvm::computeLTOCacheKey` is used to compute a SHA-1 hash from all data that might influence the result of ThinLTO on a module. In addition to the module imports/exports that we manually track, it also hashes information about global variables (e.g. their liveness) which might be used during optimization. By using this function, we shouldn't have to worry about new LLVM passes breaking our module re-use behavior. In LLVM, the output of this function forms part of the filename used to store the post-ThinLTO module. To keep our current filename structure intact, this PR just writes out the mapping 'CGU name -> Hash' to a file. To determine if a post-LTO module should be reused, we compare hashes from the previous session. This should unblock PR #75199 - by sheer chance, it seems to have hit this issue due to the particular CGU partitioning and optimization decisions that end up getting made.

view details

Hanif Bin Ariffin

commit sha dc655b28424549a4775bc2e8c9021d44482bccb1

Prevent stackoverflow

view details

push time in 14 days

pull request commentrust-lang/rust

Support custom allocators in `Box`

As far as I can see, the crater run only has one error, which is related to this PR: The window-crate failed to compile, as it could not infer A. This is the code snippet, which failed:

struct Wayland {
   // ...
   draw: Option<NonNull<dyn crate::Draw>>,
}

impl Wayland {
    fn connect(&mut self, draw: &mut Box<dyn crate::Draw>) {
        self.draw = NonNull::new(Box::into_raw(unsafe {
            std::mem::transmute_copy(draw)
        }));
        // ...
    }
}

Does this means, that any code, which constructs Box with mem::transmute(_copy) could fail? Is this even guaranteed to be backwards compatible?

In either case, the snippet should be changed to self.draw = NonNull::new(draw). cc @libcala

TimDiekmann

comment created time in 14 days

push eventTimDiekmann/rust

Tim Diekmann

commit sha d5720bba8f5b278616a2fbd0da39478879a3f68b

Fix mir-opt output for 32 bit

view details

push time in 23 days

pull request commentrust-lang/rust

Support custom allocators in `Box`

Rebased onto master to include #77515.

@rustbot modify labels: +S-waiting-on-review -S-blocked

TimDiekmann

comment created time in 23 days

push eventTimDiekmann/rust

kadmin

commit sha 8894b366fdb976a703fe76010f6e56c591cada1f

Remove error message in specific case In the case that a trait is not implemented for an ADT with type errors, cancel the error.

view details

Cassandra Fridkin

commit sha a009e2838b25df2761093d727d322a59f69d8f68

There isn't a way to pass --remove yet, but you can rm if u like

view details

Alexis Bourget

commit sha 492826ac144666c75d68bc0a0121453ecc08561f

Add a note about the panic behavior of math operations on time objects

view details

CAD97

commit sha 728938346b02a9688c44253c19b15baa7551fd80

Adjust rc::Weak::from_raw to support unsized T

view details

CAD97

commit sha 0c61ce2cf0560577923abafab2e5bfce14516525

?Sized bounds for rc::Weak::as_ptr and friends

view details

CAD97

commit sha 5e7406c9569dce75a042ce079918cf03cfca842a

Adjust sync::Weak::from_raw to support unsized T

view details

CAD97

commit sha 9d9903c5a50bb1f5b5fc3045b86172279eff7d30

Allow Weak::as_ptr and friends for unsized T

view details

CAD97

commit sha 3d07108d3600dff50e564f57dd390337dbe14d55

Add tests for weak into/from raw

view details

Jubilee Young

commit sha ac96f5b39ca7d9fad8571595c476c2db0bce8438

Test and reject out-of-bounds shuffle vectors

view details

Hoe Hao Cheng

commit sha 3c582db8cb43dac1d13dd653078a68753d4baa99

Implement as_ne_bytes for floats and integers

view details

LingMan

commit sha a6ff925f8b5598a1f6d84964525baa1d4a08fd63

Reduce boilerplate with the matches! macro Replaces simple bool `match`es of the form match $expr { $pattern => true _ => false } and their inverse with invocations of the matches! macro.

view details

sharnoff

commit sha 8a011b5da2cc289fb7d970492ea4111980676412

minor doc changes, attribute orderings

view details

Valerii Lashmanov

commit sha 5c224a484dc6ba2a70c9cd0d73a04849f6d7aa68

MiniSet/MiniMap moved and renamed into SsoHashSet/SsoHashMap It is a more descriptive name and with upcoming changes there will be nothing "mini" about them.

view details

Valerii Lashmanov

commit sha 0600b178aa0e9f310067bf8ccaf736e77a03eb1d

SsoHashSet/SsoHashMap API greatly expanded Now both provide almost complete API of their non-SSO counterparts.

view details

Valerii Lashmanov

commit sha 41942fac7d0711c6b3d0faa69748e22c0eb41388

SsoHashSet reimplemented as a wrapper on top of SsoHashMap SsoHashSet::replace had to be removed because it requires missing API from SsoHashMap. It's not a widely used function, so I think it's ok to omit it for now. EitherIter moved into its own file. Also sprinkled code with #[inline] attributes where appropriate.

view details

Valerii Lashmanov

commit sha 92a0668c20b8dea00d8739dce2243113f518b427

SsoHashMap minor refactoring, SSO_ARRAY_SIZE introduced

view details

Oliver Scherer

commit sha 43c181bac4d88dbe7bdd762688dcf18313f01093

Use `tracing` spans to trace the entire MIR interp stack

view details

kadmin

commit sha 3f1d2aadd19c3cb71f1d88fb0b0c565808a3c040

Use more efficient scheme for display u128/i128 Add zero padding Add benchmarks for fmt u128 This tests both when there is the max amount of work(all characters used) And least amount of work(1 character used)

view details

Shahar Or (mightyiam)

commit sha badf4afdd5010fa057d42c0fce56afd10eca54f7

core::global_allocator docs link to std::alloc::GlobalAlloc

view details

Joshua Nelson

commit sha 6533c29bea5416c62c098f369553ed2b6c2c9eae

Remove --cfg dox from rustdoc.rs This was added in https://github.com/rust-lang/rust/pull/53076 because several dependencies were using `cfg(dox)` instead of `cfg(rustdoc)`. I ran `rg 'cfg\(dox\)'` on the source tree with no matches, so I think this is now safe to remove.

view details

push time in 23 days

Pull request review commentrust-lang/rust

Support custom allocators in `Box`

 impl<T: ?Sized> Box<T> {     #[stable(feature = "box_raw", since = "1.4.0")]     #[inline]     pub unsafe fn from_raw(raw: *mut T) -> Self {-        Box(unsafe { Unique::new_unchecked(raw) })+        unsafe { Self::from_raw_in(raw, Global) }+    }+}++impl<T: ?Sized, A: AllocRef> Box<T, A> {+    /// Constructs a box from a raw pointer in the given allocator.+    ///+    /// After calling this function, the raw pointer is owned by the+    /// resulting `Box`. Specifically, the `Box` destructor will call+    /// the destructor of `T` and free the allocated memory. For this+    /// to be safe, the memory must have been allocated in accordance+    /// with the [memory layout] used by `Box` .+    ///+    /// # Safety+    ///+    /// This function is unsafe because improper use may lead to+    /// memory problems. For example, a double-free may occur if the+    /// function is called twice on the same raw pointer.+    ///+    ///+    /// # Examples+    ///+    /// Recreate a `Box` which was previously converted to a raw pointer+    /// using [`Box::into_raw_with_alloc`]:+    /// ```+    /// #![feature(allocator_api)]+    ///+    /// use std::alloc::System;+    ///+    /// let x = Box::new_in(5, System);+    /// let (ptr, alloc) = Box::into_raw_with_alloc(x);+    /// let x = unsafe { Box::from_raw_in(ptr, alloc) };+    /// ```+    /// Manually create a `Box` from scratch by using the system allocator:+    /// ```+    /// use std::alloc::{AllocRef, System};

Thank you, I noticed a few other doc-tests which needs adjustments. Will update then when chalk was updated.

TimDiekmann

comment created time in 25 days

PullRequestReviewEvent

Pull request review commentrust-lang/rust

reuse allocations for vec.append(vec) and vec.extend(vec.into_iter()) when the LHS is empty

 impl<T> Vec<T> {     #[inline]     #[stable(feature = "append", since = "1.4.0")]     pub fn append(&mut self, other: &mut Self) {+        if self.len == 0 && self.capacity() < other.len {

This could be rephrased to something like

Vec will never automatically shrink itself, if allocations or deallocations would be needed.

the8472

comment created time in a month

PullRequestReviewEvent

Pull request review commentrust-lang/rust

reuse allocations for vec.append(vec) and vec.extend(vec.into_iter()) when the LHS is empty

 impl<T> Vec<T> {     #[inline]     #[stable(feature = "append", since = "1.4.0")]     pub fn append(&mut self, other: &mut Self) {+        if self.len == 0 && self.capacity() < other.len {

I don't think it's expected from the current guarantees, that a passed vector have a smaller capacity than before. However I'm not an expert on this and the libs-team should look into this.

cc @Amanieu

the8472

comment created time in a month

PullRequestReviewEvent

push eventTimDiekmann/rust

Tim Diekmann

commit sha dacca08f983dd9766d180dd6bc725d9840fb3e99

Rename `AllocErr` to `AllocError` in leak-test

view details

push time in a month

IssuesEvent

issue commentrust-lang/wg-allocators

Tracking Issue for structs which needs an allocator

I just answered the question right above. And my fat fingers clicked the wrong button :D

TimDiekmann

comment created time in a month

issue closedrust-lang/wg-allocators

Tracking Issue for structs which needs an allocator

This WG wants to associate an allocator for all suitable structs. This issue tracks those structs, which are covered so far (non-exhaustive list):

  • [ ] Box<T, A>: rust-lang/rust#77187
  • [ ] Rc<T, A>
  • [ ] Arc<T, A>
  • [ ] String<A>
  • [ ] Vec<T, A>: alloc_wg
  • [ ] VecDeque<T, A>
  • [ ] LinkedList<T, A>
  • [ ] HashMap<K, V, S, A>: TBD: in hashbrown crate?
  • [ ] BTreeMap<K, V, A>: rust-lang/rust#77438
  • [ ] HashSet<T, S, A>
  • [ ] BTreeSet<T, A>
  • [ ] BinaryHeap<T, A>
  • [ ] (CString<A>)
  • [ ] (OsString<A>)
  • [ ] (PathBuf<A>)

closed time in a month

TimDiekmann

pull request commentrust-lang/rust

BTreeMap: Support custom allocators

cc @Amanieu

exrook

comment created time in a month

Pull request review commentrust-lang/rust

BTreeMap: Support custom allocators

 use UnderflowResult::*; /// *stat += random_stat_buff(); /// ``` #[stable(feature = "rust1", since = "1.0.0")]-pub struct BTreeMap<K, V> {+pub struct BTreeMap<K, V, #[unstable(feature = "allocator_api", issue = "32838")] #[unstable(feature = "allocator_api", issue = "32838")] A: AllocRef = Global> {

You added #[unstable] twice

pub struct BTreeMap<K, V, #[unstable(feature = "allocator_api", issue = "32838")] A: AllocRef = Global> {
exrook

comment created time in a month

Pull request review commentrust-lang/rust

BTreeMap: Support custom allocators

 impl<K: Ord, V> BTreeMap<K, V> {     /// ```     #[stable(feature = "rust1", since = "1.0.0")]     pub fn clear(&mut self) {-        *self = BTreeMap::new();+        let alloc = unsafe {+            // drop all elements and retrieve allocator+            ptr::read(self).into_iter().into_alloc()+        };+        *self = BTreeMap::new_in(alloc);+    }+}+impl<K: Ord, V, A: AllocRef> BTreeMap<K, V, A> {+    /// Makes a new empty BTreeMap with a reasonable choice for B.+    ///+    /// # Examples+    ///+    /// Basic usage:+    ///+    /// ```+    /// use std::collections::BTreeMap;+    ///+    /// let mut map = BTreeMap::new();

In this example, new_in should be used.

exrook

comment created time in a month

PullRequestReviewEvent
PullRequestReviewEvent

issue commentrust-lang/wg-allocators

Roadmap

@Wodann FYI: We have started to implement #7.

TimDiekmann

comment created time in a month

issue closedrust-lang/wg-allocators

Rename AllocErr to AllocError

Almost every error type in the standard library is named SomethingError, not SomethingErr. The one exception is LayoutErr, which is stable and so can’t easily be renamed. Although LayoutErr has more "proximity" to AllocErr (being in the same module) I think we should leave it as a lone inconsistency rather than make it a second naming pattern to follow.

closed time in a month

SimonSapin

issue commentrust-lang/wg-allocators

Tracking Issue for structs which needs an allocator

Currently, there is a PR upstream for Box and BTreeMap. After Box is merged, I'll adjust Vec.

cc @exrook

TimDiekmann

comment created time in a month

pull request commentrust-lang/rust

BTreeMap: Support custom allocators

@rustbot modify labels: -S-waiting-on-review -S-blocked

exrook

comment created time in a month

push eventTimDiekmann/rust

Nazım Can Altınova

commit sha a313abe3ba989ba4b6c041627c903488886f8559

Manually implement Debug for BTreeMap::{IntoKeys,IntoValues} structs

view details

Nazım Can Altınova

commit sha 456738e3d1ad7dadffaed287d3055ca38b5fa375

Only print values in the Debug of HashMap::ValuesMut struct

view details

Nazım Can Altınova

commit sha c346e89db8a57e15111daa35685a2542d3be7c77

Manually implement Debug for BTreeMap::ValuesMut struct Deriving debug prints all the values including keys. But ValuesMut struct should only print the values.

view details

Nazım Can Altınova

commit sha 8faf550e5f7211188bc9560ae459c155fb1aafdf

Remove the unused bounds from Debug impl of HashMap::{IntoKeys,IntoValues}

view details

Jubilee Young

commit sha 247b73939a619ea4dcb2affbe1c285d20d93a0b8

Move Wrapping<T> ui tests into library

view details

Jubilee Young

commit sha 797cb9526a627c37b9bb9f6be6d3b54789b67c26

Fix to libstd test

view details

Mara Bos

commit sha 84ef603c8400db203fefd714de963c88e5523424

Fix 'FIXME' about using NonZeroU32 instead of u32. It was blocked by #58732 (const fn NonZeroU32::new), which is fixed now.

view details

Without Boats

commit sha 82f5928ca68acceb1d1bd9e2b09554744e4a1dfe

Make RawFd implement the RawFd traits

view details

Without Boats

commit sha acc136ce0a665a32ddf1a16544b6f6d7a7153c30

fix typos

view details

Without Boats

commit sha 3fe279fc658450a3e3140f014554139493674217

spend another CI build to delete a double newline

view details

Without Boats

commit sha 35b30e29bffe8c4aa896ce53ded67c54401f7643

try again to appease tidy

view details

Tim Vermeulen

commit sha ecacc7534b6bf50205c37c89402565b82d95a257

Add advance_by and advance_back_by

view details

Matthias Krüger

commit sha 2ad46acd7fee4e193aff3fd243ca91ca092a42aa

EarlyOtherwiseBranch::run_pass(): don't convert Place to Place (clippy::useless_conversion)

view details

Matthias Krüger

commit sha d7a5c574b1010360fd840f5dfc810f2aa782eac5

use std::mem::take(x) instead of std::mem::replace(x, Default::default()) (clippy::mem_replace_with_default)

view details

Eric Huss

commit sha c29a29cba099aef1e05c83970decdcbedaabd69a

Defer Apple SDKROOT detection to link time.

view details

Eric Huss

commit sha de725fe56f338a2ceedf5dd9df5bcd86a24f8f53

Remove note about missing ios/tvos targets in platform docs. I misunderstood how this works, and I have fixed the linux builds to support ios/tvos.

view details

Guillaume Gomez

commit sha 980e1ff40f51b6b4b86ee70809d0a0055e6f9cc6

Add missing examples for Fd traits

view details

Mara Bos

commit sha f289468045c248e3543f2b0cd50cc37ecd3fd717

Stabilize slice_ptr_range. Closes #65807.

view details

Lzu Tao

commit sha d31ca4fc8ede3b4a28abea7df57e01591ee8bb7d

Move Utf8Error to new mod

view details

Lzu Tao

commit sha 5b533fccf39501bd5ca8a436da6f2d8b5999664d

Move traits implementation of str to new mod Also move FromStr trait

view details

push time in a month

delete branch TimDiekmann/rust

delete branch : alloc-ref-by-ref

delete time in a month

push eventTimDiekmann/rust

David Wood

commit sha 01f65afa4adff6dfbea84621e6851c028aaa7159

diag: improve closure/generic parameter mismatch This commit improves the diagnostic when a type parameter is expected and a closure is found, noting that each closure has a distinct type and therefore could not always match the caller-chosen type of the parameter. Signed-off-by: David Wood <david@davidtw.co>

view details

Pietro Albini

commit sha 0917b2123fff6cf5357b5edd5db6d675313ab8bd

build-manifest: move PkgType into the versions module

view details

Pietro Albini

commit sha 3bddfea7e23341f788526f8b303b9a27038511e3

build-manifest: stop receiving release numbers from bootstrap

view details

Alexis Bourget

commit sha 8aae1eee94f481bd955cff473deae1f03c313451

Move cell exterior test into library unit tests

view details

Alexis Bourget

commit sha f69c5aa428efdbc01685c3d06e63fedd3120e8e5

Move more tests using Cell to unit tests

view details

Alexis Bourget

commit sha af44a2a857618150b180dabe9c3383a3911b3640

move 'cell does not clone' test

view details

Alexis Bourget

commit sha fc152cd67e0b6d3f11f49eae43183d03a3b8bf17

move 'test zip ...' tests

view details

Alexis Bourget

commit sha 85b2d9bf6f2b04ae8996050b2fb276bd58cd92de

fmt

view details

Alexis Bourget

commit sha 949c96660c32ff9b19a639b4be607938c2262653

move format! interface tests

view details

Alexis Bourget

commit sha ed52c7bb7516f12f74704e20457d5046378a49fc

Move deref-lval test

view details

Alexis Bourget

commit sha ac39debeba2b63a39a3833e2d7451f0b1f95b5f2

Move panic safety traits tests

view details

Alexis Bourget

commit sha 8904921c1d6b3636f4352f9dd6d4875132b89998

Move array cycle test

view details

Alexis Bourget

commit sha 275eed7eb1d45e8173b932e2abfdae2201d2cf62

Move vec-slice-drop test

view details

Alexis Bourget

commit sha 6bc0357dadd9d41a8166d4c2ab8a27c0bb8150d3

Move vec-cycle test

view details

Alexis Bourget

commit sha f6a4189d05f8bc7091450289f7285819ebdd3c62

Move vec-cycle-wrapped test

view details

Alexis Bourget

commit sha 5be843fc54f80817c88438efa097a4ba81d4aa9e

Move format-ref-cell test

view details

Raoul Strackx

commit sha a13239dac2b4b50e389a3e12c638d164e620ea2f

generic ret hardening test

view details

Raoul Strackx

commit sha cd31f40b6f59c8966a09e7f1e2d6c3c5ed1570f1

generic load hardening test

view details

Pietro Albini

commit sha 89ffab76b7a17355f8fa0c82b06e6fb7ec48f09c

build-manifest: refactor detecting package versions

view details

Pietro Albini

commit sha 73d9c24b3edf0f87a6e1c78ca56349f94ced5788

build-manifest: add documentation on the PkgType methods

view details

push time in a month

pull request commentrust-lang/rust

Support custom allocators in `Box`

Rebased onto master to include #77289

TimDiekmann

comment created time in a month

pull request commentrust-lang/rust

Support custom allocators in `Box`

That's awesome, thank you!

TimDiekmann

comment created time in a month

Pull request review commentrust-lang/rust

Support custom allocators in `Box`

 impl<T: ?Sized> Box<T> {     /// ```     #[stable(feature = "box_leak", since = "1.26.0")]     #[inline]-    pub fn leak<'a>(b: Box<T>) -> &'a mut T+    pub fn leak<'a>(b: Self) -> &'a mut T     where-        T: 'a, // Technically not needed, but kept to be explicit.+        A: 'a,

I added a test, which ensures, that the allocator must not be moved while the leaked data is in use.

TimDiekmann

comment created time in a month

PullRequestReviewEvent

push eventTimDiekmann/rust

Tim Diekmann

commit sha f6b8a59ff6ccf160221c74641957974a0936f97e

Remove `Box::leak_with_alloc`

view details

Tim Diekmann

commit sha 44cfe3dee491ebdf25597e9c917551b3f1b06312

Add leak-test for box with allocator

view details

push time in a month

PR opened rust-lang/rust

Change `AllocRef::by_ref` to take `&self` instead of `&mut self`

r? @Amanieu

+1 -1

0 comment

1 changed file

pr created time in a month

create barnchTimDiekmann/rust

branch : alloc-ref-by-ref

created branch time in a month

Pull request review commentrust-lang/rust

Support custom allocators in `Box`

 impl<T: ?Sized> Box<T> {     /// ```     #[stable(feature = "box_leak", since = "1.26.0")]     #[inline]-    pub fn leak<'a>(b: Box<T>) -> &'a mut T+    pub fn leak<'a>(b: Self) -> &'a mut T     where-        T: 'a, // Technically not needed, but kept to be explicit.+        A: 'a,     {         unsafe { &mut *mem::ManuallyDrop::new(b).0.as_ptr() }     } +    /// Consumes and leaks the `Box`, returning a mutable reference,+    /// `&'a mut T`, and the allocator. Note that the type `T` must outlive the chosen lifetime+    /// `'a`. If the type has only static references, or none at all, then this+    /// may be chosen to be `'static`.+    ///+    /// This function is mainly useful for data that lives for the remainder of+    /// the program's life. Dropping the returned reference will cause a memory+    /// leak. If this is not acceptable, the reference should first be wrapped+    /// with the [`Box::from_raw`] function producing a `Box`. This `Box` can+    /// then be dropped which will properly destroy `T` and release the+    /// allocated memory.+    ///+    /// Note: this is an associated function, which means that you have+    /// to call it as `Box::leak(b)` instead of `b.leak()`. This+    /// is so that there is no conflict with a method on the inner type.+    #[unstable(feature = "allocator_api", issue = "32838")]+    #[inline]+    pub fn leak_with_alloc<'a>(b: Self) -> (&'a mut T, A)

That's indeed a problem. Do you have a solution to this or should I remove this method? Therefore also a comment should be added to into_raw_with_alloc, that the allocator may have to outlive the pointer.

TimDiekmann

comment created time in a month

PullRequestReviewEvent

Pull request review commentrust-lang/rust

Support custom allocators in `Box`

 impl<T: ?Sized> Box<T> {     /// ```     #[stable(feature = "box_leak", since = "1.26.0")]     #[inline]-    pub fn leak<'a>(b: Box<T>) -> &'a mut T+    pub fn leak<'a>(b: Self) -> &'a mut T     where-        T: 'a, // Technically not needed, but kept to be explicit.+        A: 'a,     {         unsafe { &mut *mem::ManuallyDrop::new(b).0.as_ptr() }     } +    /// Consumes and leaks the `Box`, returning a mutable reference,+    /// `&'a mut T`, and the allocator. Note that the type `T` must outlive the chosen lifetime+    /// `'a`. If the type has only static references, or none at all, then this+    /// may be chosen to be `'static`.+    ///+    /// This function is mainly useful for data that lives for the remainder of+    /// the program's life. Dropping the returned reference will cause a memory+    /// leak. If this is not acceptable, the reference should first be wrapped+    /// with the [`Box::from_raw`] function producing a `Box`. This `Box` can+    /// then be dropped which will properly destroy `T` and release the+    /// allocated memory.+    ///+    /// Note: this is an associated function, which means that you have+    /// to call it as `Box::leak(b)` instead of `b.leak()`. This+    /// is so that there is no conflict with a method on the inner type.+    #[unstable(feature = "allocator_api", issue = "32838")]+    #[inline]+    pub fn leak_with_alloc<'a>(b: Self) -> (&'a mut T, A)+    where+        A: 'a,+    {+        let manually_drop = mem::ManuallyDrop::new(b);+        let alloc = unsafe { ptr::read(&manually_drop.1) };

Ah, nice catch. So I think this way this should be safe?

let mut boxed = mem::MaybeUninit::new(b);
unsafe {
    let reference = &mut *(*b.as_mut_ptr()).0.as_ptr();
    let alloc = ptr::read(&(*b.as_mut_ptr()).1);
    (reference, alloc)
}

Or would it also be safe to obtain the reference before reading the allocator?

TimDiekmann

comment created time in a month

PullRequestReviewEvent

pull request commentrust-lang/rust

Support custom allocators in `Box`

Rebased onto master to include #77118

TimDiekmann

comment created time in a month

push eventTimDiekmann/rust

Laurence Tratt

commit sha 73ada2d40429488aaaacf37b608bababc137b910

Explicitly document the size guarantees that Option makes. Triggered by a discussion on wg-unsafe-code-guidelines about which layouts of `Option<T>` one can guarantee are optimised to a single pointer.

view details

Laurence Tratt

commit sha f5118a525fcf9db4102d903650331039158eff11

Clarify and add guarantee about `transmute`.

view details

Laurence Tratt

commit sha 83f47aa11bd664ed8a15ef9833063833b7b3e71c

Be clear about the reverse `transmute` guarantees.

view details

Laurence Tratt

commit sha f3d7196caec3f54e572c7389b1cef9fd9e62c1ed

Be clearer about Some/None transmute.

view details

Laurence Tratt

commit sha 8cb8955d570c76631840bfc98825ca49c0dd8eea

Change notation. Co-authored-by: Ralf Jung <post@ralfj.de>

view details

Laurence Tratt

commit sha 55802e3bf3bf6d1db5c76aea581a7912bd752890

Add Rust function pointers. Co-authored-by: Ralf Jung <post@ralfj.de>

view details

Laurence Tratt

commit sha 68209c3fe4e0f5c3758f18e98efc175af31c2e51

Rename the types for clarity.

view details

Laurence Tratt

commit sha 9bac5774d7b452b2227c9fb77a4c6de3f432ee55

Grammar tweak.

view details

Erik Desjardins

commit sha d3b9ece4c0028ff7e36e34df2d2b26366f9c0648

add tests related to tuple scalar layout with ZST in last field

view details

Erik Desjardins

commit sha e5d85f917b8965a5e62513c17cbb887366b152bc

allow reordering of the last field of a MaybeUnsized struct if it's a ZST

view details

Erik Desjardins

commit sha e9bc3ddb073f2261ac46832d985efe8db863ed6a

test that we do not change the offset of ZST tuple fields when unsizing

view details

Erik Desjardins

commit sha 68217c9e0f1269d29b4c1c72d08fb1b95bf441cd

ignore zst offsets instead

view details

Erik Desjardins

commit sha 6fc1d8bc13124bb134d7ab54e56237821a55912e

add codegen test

view details

Erik Desjardins

commit sha 24e0913e37cc6fc363b37d13bf519db212f175a2

handle vector layout

view details

Esteban Küber

commit sha 2ac89ff994c9ddcc49eed2b06ff5327bc09f4118

Point at named argument not found when using `format_args_capture` instead of whole format string

view details

Mara Bos

commit sha 26d6081f1d1a2005be87bbe47f6fcda270cfd016

Relax promises about condition variable. This allows for futex or thread parking based implementations in the future.

view details

Oliver Scherer

commit sha b54f122a1cb2593325501a2ed5b3fbfc47293615

Merge tuple and struct pattern generation.

view details

Oliver Scherer

commit sha 34c62e0abc82b7302a3b0ee16dfe445e1330ce4c

Add a query for dereferencing constants of reference type

view details

Oliver Scherer

commit sha b2532a87306fafd097241a80f92f68b10df0cba4

Implement destructuring for all aggregates and for references

view details

Lzu Tao

commit sha 3e08354fb0dc7a5f7733da9b308d483b9c1d2514

Correct file path after some restructures in compiler

view details

push time in a month

issue commentrust-lang/wg-allocators

Unstable type parameters on stable types

It's now possible to add stability annotations on generic parameters as seen in https://github.com/rust-lang/rust/pull/77187. Many thanks for @Avi-D-coder to make this possible. Also thank you for @varkor for reviewing the changes and @exrook to catch this up, so it's merged now!

SimonSapin

comment created time in a month

issue closedrust-lang/wg-allocators

Unstable type parameters on stable types

This is related to #1 but not identical. When adding a defaulted type parameter to a stable type, for example changing:

struct Vec<T> {…}

To:

struct Vec<T, A: Alloc = Global> {…}

We would like to experiment with this change on Rust Nightly before it affects users one the Stable channel. That is, we would like to keep the type parameter unstable. Ideally, even the existence of this type parameter should not affect the stable channel at all.

As far as I understand this is not possible today. Ways forward include:

  • Extend the stability mechanism in the language to support unstable type parameters. This itself would likely take significant time to design and implement.

  • Accept that the existence of the new type parameter is instantly stable as soon as it lands, and hope that the trait that constraints this parameter being unstable is enough to avoid locking is into some API detail that we might want to change later. In this case #1 needs to be resolved before adding the parameter.

  • Avoid adding type parameters at all to stable types. Define new types instead. This would mean that e.g. &mut NewVec<T, Global> could not be passed where &mut Vec<T> is expected.

closed time in a month

SimonSapin

pull request commentrust-lang/rust

Support custom allocators in `Box`

That would be great, thank you!

TimDiekmann

comment created time in a month

pull request commentrust-lang/rust

Support custom allocators in `Box`

@nikomatsakis wrote in https://github.com/rust-lang/rust/pull/71873#issuecomment-632116962

The chalk error is legit in the sense that we haven't defined what fundamental means for a type with multiple type parameters. I guess we will ignore all but the first, but we're going to have to spend at least some time thinking about how to use this to break coherence :)

What is the state of this?

TimDiekmann

comment created time in a month

PR opened rust-lang/rust

Support custom allocators in `Box`

r? @Amanieu

This pull request requires a crater run.

Prior work:

Currently blocked on #77118

+524 -211

0 comment

27 changed files

pr created time in a month

create barnchTimDiekmann/rust

branch : box-alloc

created branch time in a month

push eventTimDiekmann/alloc-wg

TimDiekmann

commit sha 4d001fc9eab25a5904cbe0c1346ed419a80f086f

Automated deployment: Thu Sep 24 22:24:36 UTC 2020 8f2cfbf197e790972f3b89877f4a3e7f8ba14d25

view details

push time in a month

push eventTimDiekmann/alloc-wg

Tim Diekmann

commit sha 8f2cfbf197e790972f3b89877f4a3e7f8ba14d25

Update README.md

view details

push time in a month

pull request commentTimDiekmann/alloc-wg

Sync BTreeMap with stdlib

As soon as the stability annotations on generics has landed I'll make a PR for Box as pretty much everything depends on it. It's bit tricky though as compiler magic is involved and a crater run has to be done so don't expect it to land before next week. :)

On Sep 24, 2020, 23:12, at 23:12, exrook notifications@github.com wrote:

I've had the same thoughts, and I've been working on getting the changes pushed in the other direction as well. However the stdlib btreemap implementation diverged a bit since my initial changes, and it was easier to get the new changes working here first. (Notably, I need Box<T, A>, which needs RawVec<T, A> in order to get anything to compile)

-- You are receiving this because you modified the open/close state. Reply to this email directly or view it on GitHub: https://github.com/TimDiekmann/alloc-wg/pull/25#issuecomment-698591140

exrook

comment created time in a month

push eventTimDiekmann/alloc-wg

TimDiekmann

commit sha f2229ff2a026df051e50fe9569172289bd2cfe10

Automated deployment: Thu Sep 24 21:09:51 UTC 2020 ad59e568472d7ee1e4db9c57e95e19f986349d8e

view details

push time in a month

push eventTimDiekmann/alloc-wg

Jacob Hughes

commit sha 91439a10950656c4bb188e4e7a81d70cb8707c74

Sync BTreeMap with stdlib

view details

Jacob Hughes

commit sha f635f5cdba390e4348b0837a1aca437194a35363

Sort feature flags & lint declarations

view details

Tim Diekmann

commit sha ad59e568472d7ee1e4db9c57e95e19f986349d8e

Merge pull request #25 from exrook/master Sync BTreeMap with stdlib

view details

push time in a month

PR merged TimDiekmann/alloc-wg

Sync BTreeMap with stdlib

I've pulled in the changes made to BTreeMap in stdlib that happened since my first pull of the BTreeMap code.

These changes are based off the stdlib BTreeMap as of commit 3a4da87f58099f08620a9a3e812abd77301cafb2

I also sorted the feature flags & lint definitions since they didn't seem to follow any pattern.

+1540 -888

1 comment

8 changed files

exrook

pr closed time in a month

pull request commentTimDiekmann/alloc-wg

Sync BTreeMap with stdlib

Do you think it's worth the effort on alloc-wg right now as we can push those changes upstream pretty soon?

I'm planing on deprecating this crate after most collections has been updated upstream as there is no point in keeping alloc-wg updated.

exrook

comment created time in a month

issue commentrust-lang/wg-allocators

Rename AllocErr to AllocError

I believe so

Assuming this works, we should rename LayoutErr to LayoutError, add pub type LayoutErr = LayoutError, and do a crater-run just to be sure.

However, if LayoutErr will be renamed should be discussed in a separate issue, as this is way more complicated than renaming AllocErr (as LayoutErr is stable).


I'd go with @exrook suggestion and just rename AllocErr to AllocError

to be consistent with the majority of the other error types.

AllocError is by far not common enough to name it alloc::Error like fmt::Error or io::Error.

SimonSapin

comment created time in a month

issue commentrust-lang/wg-allocators

Rename AllocErr to AllocError

Iff we change LayoutErr to LayoutError, do we still want it in core::alloc or should we move it to core::mem? Related: https://github.com/rust-lang/wg-allocators/issues/59 and https://github.com/rust-lang/rust/pull/71856

SimonSapin

comment created time in a month

issue commentrust-lang/wg-allocators

Rename AllocErr to AllocError

Is it possible to write

#[stable]
pub type LayoutError = LayoutErr;

and deprecate LayoutErr without getting a warning when using LayoutError?

Is a type alias 100% backwards compatible when changing it to the actual struct? Or vice versa?

SimonSapin

comment created time in a month

issue commentrust-lang/wg-allocators

Rename AllocErr to AllocError

We should decide, if we want AllocErr to be renamed to Error or AllocError. Other modules like core::fmt also has the Error type and it's known pattern to rust users, that different Errors occurs in core/std. Anyway, we also have core::alloc::LayoutErr (stable) and this will not be moved until we use Layout outside of std::alloc. However, AllocErr is the "main-error" type in core::alloc, which is an argument for renaming it to Error.

One other thing to consider is, that AllocError may occure alongside other errors more often as soon as a user decides to use a fallible allocation API.

We basically have to decide, if we want to go the old std-way or the explicit way here.

SimonSapin

comment created time in a month

issue closedrust-lang/wg-allocators

Change AllocRef to take &self

This has several advantages:

  • AllocRef can now be used by concurrent (lock-free) data structures which only have &self operations. Currently the allocator would need to be wrapped in a mutex even if the allocator is thread-safe.
  • Allocators can directly expose whether they are thread-safe or not with Sync. This bound is inherited by data structures using an allocator: a lock-free queue would only be Sync if its allocator is Sync.
  • We can define a blanket implementation of AllocRef for all types implementing GlobalAlloc. This would allow us to change #[global_allocator] to require AllocRef instead of GlobalAlloc. This is not possible if AllocRef methods take &mut self.

closed time in a month

Amanieu

Pull request review commentrust-lang/rust

[WIP] Changing the alloc() to accept &self instead of &mut self

 where     A: AllocRef + ?Sized,

AllocRef::by_ref should also return &Self.

blitzerr

comment created time in a month

PullRequestReviewEvent

Pull request review commentrust-lang/rust

[WIP] Changing the alloc() to accept &self instead of &mut self

 struct A; unsafe impl alloc::GlobalAlloc for A {     unsafe fn alloc(&self, layout: Layout) -> *mut u8 {         HITS.fetch_add(1, Ordering::SeqCst);-        System.alloc(layout)+        AllocRef::alloc(&System, layout).unwrap().as_mut_ptr()

This should return ptr::null_mut() on failure. You can simply use GlobalAlloc instead:

        alloc::GlobalAlloc::alloc(&System, layout)
blitzerr

comment created time in a month

PullRequestReviewEvent

pull request commentrust-lang/rust

[WIP] Changing the alloc() to accept &self instead of &mut self

Could you rebase onto master and force push so we don't have the changes from all the other commits?

blitzerr

comment created time in a month

Pull request review commentrust-lang/rust

[WIP] Changing the alloc() to accept &self instead of &mut self

 fn allocator_param() {     // A dumb allocator that consumes a fixed amount of fuel     // before allocation attempts start failing.     struct BoundedAlloc {-        fuel: usize,+        fuel: RefCell<usize>,

I think Cell should be used here instead.

blitzerr

comment created time in a month

PullRequestReviewEvent
PullRequestReviewEvent

startedrune-rs/rune

started time in 2 months

issue commentrust-lang/wg-allocators

Change AllocRef to take &self

As @Amanieu pointed out in https://github.com/rust-lang/wg-allocators/issues/55#issuecomment-683315523 I think it's obvious, that we don't want AllocRef to take &mut self, as it's hard to use. In fact, I believe that Pattern where &A: Trait is very little used and we should take care that the application of the API should be as simple as possible, if necessary at the expense of implementing an allocator, since we can assume that the API is used more often than implemented. As a user of the API I expect to just pull a crate, throw in an allocator and it should work just like in any other API. As far as I can see, the only unresolved question is, if &mut self is needed for an allocator to perform well. Just like BuildAllocRef (#12) adding AllocRefMut (without having a strong opinion on the name) could be added in a backwards compatible way. I think we should proceed and change the signature to &self for the sake of usability.

Amanieu

comment created time in 2 months

issue commentrust-lang/wg-allocators

Change AllocRef to take &self

I think we should ask if there are allocators, which may be slower using &self. Any logic could be wrapped in a mutex or similar.

Amanieu

comment created time in 2 months

issue commentrust-lang/wg-allocators

Change AllocRef to take &self

I don't think the allocator trait should require Send or Sync and thus not be named after it.

Amanieu

comment created time in 2 months

issue commentrust-lang/wg-allocators

Change AllocRef to take &self

That's the GlobalAlloc approach and obviously &mut self is easier to implement, especially as you may not need to have &self version. However I like to come back to an old Idea, came up again in #71: Change AllocRef to take &self, add AllocRefMut which takes &mut self, and provide a blanket implementation for AllocRefMut where A: AllocRef. This way we would have the best of both worlds.

Amanieu

comment created time in 2 months

issue closedrust-lang/wg-allocators

What about AllocRef and SyncAllocRef?

I feel like this would provide the most ergonomic solution for working with both single-threaded and multi-threaded collections.

For a stack allocator, you'd pass &mut A into the collection. For a collection like a shared hashmap, you'd use an allocator that supported concurrent allocations and pass in &A. AllocRef would be implemented for either &A and &mut A depending on if it was concurrent or not.

It's definitely possible I'm not seeing some downsides of this, but it seems like the best of both worlds to me.

See my reply lower down.

closed time in 2 months

lachlansneff

issue commentrust-lang/wg-allocators

What about AllocRef and SyncAllocRef?

The idea isn't new, but I totally forgot about this approach, thank you for bringing this back! However I think this should be discussed in #55. I close this in favor of the other issue.

lachlansneff

comment created time in 2 months

issue commentrust-lang/wg-allocators

Has alloc taking `self` been ruled out?

Sadly this isn't possible, I already tried that in the alloc-wg crate. When taking self, a Copy bound is needed on AllocRef, otherwise most collection wouldn't work without many alloc.clone(). Requiring Copy or Clone is not possible as &mut does not implement it.

lachlansneff

comment created time in 2 months

issue commentlibratbag/libratbag

Logitech G502 and G915 DeviceMatch missing

Ah I see. Do you want me to keep this issue open? The linked issue is about the G915 TKL, which is a (slightly) different device.

TimDiekmann

comment created time in 2 months

issue commentlibratbag/libratbag

Logitech G502 and G915 DeviceMatch missing

Thanks for the response! Somehow the g502 is now showing up:

$ ratbagctl
chanting-squirrel:   Logitech G502  
# ratbagd --verbose=raw

<details><summary>Output</summary>

Initializing libratbag
ratbag debug: New device: Logitech USB Receiver
ratbag debug: Using data directory '/usr/share/libratbag'
ratbag debug: No data file found for 046d:c539
ratbag debug: New device: Logitech USB Receiver
ratbag debug: Using data directory '/usr/share/libratbag'
ratbag debug: No data file found for 046d:c539
ratbag debug: New device: Logitech G502
ratbag debug: Using data directory '/usr/share/libratbag'
ratbag debug: device assigned driver hidpp20
ratbag debug: hidraw info: bus 0x03 vendor 0x46d product 0xffffc539
ratbag debug: hidraw info: bus 0x03 vendor 0x46d product 0xffffc539
ratbag debug: hidraw info: bus 0x03 vendor 0x46d product 0x407f
ratbag debug: Logitech G502 is device '/dev/hidraw6'.
ratbag debug: Parsing HID report descriptor
ratbag debug: Parsing HID report descriptor
ratbag debug: - HID report ID 01
ratbag debug: - HID report ID 0e
ratbag debug: - HID report ID 02
ratbag debug: - HID report ID 10
ratbag debug: - HID report ID 11
ratbag debug: - HID report ID 20
ratbag debug: - HID report ID 21
ratbag debug: hidpp: device supports short reports
ratbag debug: hidpp: device supports long reports
ratbag raw: hidpp write:  10 ff 00 18 00 00 00
ratbag raw: hidpp read:   11 01 00 18 04 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 00 08 00 01 00
ratbag raw: hidpp read:   11 01 00 08 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x0001 is at 0x01
ratbag raw: hidpp write:  10 ff 01 08 00 00 00
ratbag raw: hidpp read:   11 01 01 08 1d 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 00 00 00
ratbag raw: hidpp read:   11 01 01 18 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 01 00 00
ratbag raw: hidpp read:   11 01 01 18 00 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 02 00 00
ratbag raw: hidpp read:   11 01 01 18 00 03 00 02 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 03 00 00
ratbag raw: hidpp read:   11 01 01 18 00 05 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 04 00 00
ratbag raw: hidpp read:   11 01 01 18 1d 4b 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 05 00 00
ratbag raw: hidpp read:   11 01 01 18 00 20 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 06 00 00
ratbag raw: hidpp read:   11 01 01 18 10 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 07 00 00
ratbag raw: hidpp read:   11 01 01 18 80 70 00 04 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 08 00 00
ratbag raw: hidpp read:   11 01 01 18 13 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 09 00 00
ratbag raw: hidpp read:   11 01 01 18 81 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 0a 00 00
ratbag raw: hidpp read:   11 01 01 18 81 10 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 0b 00 00
ratbag raw: hidpp read:   11 01 01 18 80 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 0c 00 00
ratbag raw: hidpp read:   11 01 01 18 22 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 0d 00 00
ratbag raw: hidpp read:   11 01 01 18 18 02 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 0e 00 00
ratbag raw: hidpp read:   11 01 01 18 18 03 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 0f 00 00
ratbag raw: hidpp read:   11 01 01 18 18 05 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 10 00 00
ratbag raw: hidpp read:   11 01 01 18 18 06 60 04 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 11 00 00
ratbag raw: hidpp read:   11 01 01 18 18 11 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 12 00 00
ratbag raw: hidpp read:   11 01 01 18 18 30 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 13 00 00
ratbag raw: hidpp read:   11 01 01 18 18 90 60 04 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 14 00 00
ratbag raw: hidpp read:   11 01 01 18 18 91 60 04 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 15 00 00
ratbag raw: hidpp read:   11 01 01 18 18 a1 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 16 00 00
ratbag raw: hidpp read:   11 01 01 18 18 01 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 17 00 00
ratbag raw: hidpp read:   11 01 01 18 18 b1 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 18 00 00
ratbag raw: hidpp read:   11 01 01 18 1d f3 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 19 00 00
ratbag raw: hidpp read:   11 01 01 18 1e 00 40 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 1a 00 00
ratbag raw: hidpp read:   11 01 01 18 1e b0 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 1b 00 00
ratbag raw: hidpp read:   11 01 01 18 18 63 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 1c 00 00
ratbag raw: hidpp read:   11 01 01 18 1e 22 60 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 01 18 1d 00 00
ratbag raw: hidpp read:   11 01 01 18 21 21 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag debug: 'Logitech G502' is using protocol v4.2
ratbag raw: 'Logitech G502' has 30 features
ratbag raw: Init feature HIDPP_PAGE_ROOT (0x0000) 
ratbag raw: hidpp write:  10 ff 00 08 00 00 00
ratbag raw: hidpp read:   11 01 00 08 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x0000 is at 0x00
ratbag raw: Init feature HIDPP_PAGE_FEATURE_SET (0x0001) 
ratbag raw: hidpp write:  10 ff 00 08 00 01 00
ratbag raw: hidpp read:   11 01 00 08 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x0001 is at 0x01
ratbag raw: Init feature HIDPP_PAGE_DEVICE_INFO (0x0003) 
ratbag raw: hidpp write:  10 ff 00 08 00 03 00
ratbag raw: hidpp read:   11 01 00 08 02 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x0003 is at 0x02
ratbag raw: unknown feature 0x0003
ratbag raw: Init feature HIDPP_PAGE_DEVICE_NAME (0x0005) 
ratbag raw: hidpp write:  10 ff 00 08 00 05 00
ratbag raw: hidpp read:   11 01 00 08 03 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x0005 is at 0x03
ratbag raw: unknown feature 0x0005
ratbag raw: Init feature HIDPP_PAGE_WIRELESS_DEVICE_STATUS (0x1d4b) 
ratbag raw: hidpp write:  10 ff 00 08 1d 4b 00
ratbag raw: hidpp read:   11 01 00 08 04 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1d4b is at 0x04
ratbag raw: unknown feature 0x1d4b
ratbag raw: Init feature HIDPP_PAGE_RESET (0x0020) 
ratbag raw: hidpp write:  10 ff 00 08 00 20 00
ratbag raw: hidpp read:   11 01 00 08 05 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x0020 is at 0x05
ratbag raw: unknown feature 0x0020
ratbag raw: Init feature HIDPP_PAGE_BATTERY_VOLTAGE (0x1001) 
ratbag raw: hidpp write:  10 ff 00 08 10 01 00
ratbag raw: hidpp read:   11 01 00 08 06 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1001 is at 0x06
ratbag raw: hidpp write:  10 ff 06 08 00 00 00
ratbag raw: hidpp read:   11 01 06 08 0f f1 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag debug: device battery voltage is 4081mv, status 00 
ratbag raw: Init feature HIDPP_PAGE_COLOR_LED_EFFECTS (0x8070) 
ratbag raw: hidpp write:  10 ff 00 08 80 70 00
ratbag raw: hidpp read:   11 01 00 08 07 00 04 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x8070 is at 0x07
ratbag debug: device has color effects
ratbag raw: Init feature 0x1300 (0x1300) 
ratbag raw: hidpp write:  10 ff 00 08 13 00 00
ratbag raw: hidpp read:   11 01 00 08 08 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1300 is at 0x08
ratbag debug: device has non-rgb leds
ratbag raw: Init feature HIDPP_PAGE_ONBOARD_PROFILES (0x8100) 
ratbag raw: hidpp write:  10 ff 00 08 81 00 00
ratbag raw: hidpp read:   11 01 00 08 09 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x8100 is at 0x09
ratbag debug: device has onboard profiles
ratbag raw: Init feature HIDPP_PAGE_MOUSE_BUTTON_SPY (0x8110) 
ratbag raw: hidpp write:  10 ff 00 08 81 10 00
ratbag raw: hidpp read:   11 01 00 08 0a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x8110 is at 0x0a
ratbag debug: device has configurable mouse button spy
ratbag raw: Init feature HIDPP_PAGE_ADJUSTABLE_REPORT_RATE (0x8060) 
ratbag raw: hidpp write:  10 ff 00 08 80 60 00
ratbag raw: hidpp read:   11 01 00 08 0b 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x8060 is at 0x0b
ratbag debug: device has adjustable report rate
ratbag raw: hidpp write:  10 ff 0b 08 00 00 00
ratbag raw: hidpp read:   11 01 0b 08 8b 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 0b 18 00 00 00
ratbag raw: hidpp read:   11 01 0b 18 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag debug: report rate is 500
ratbag debug: device has 4 report rates
ratbag raw: Init feature HIDPP_PAGE_ADJUSTABLE_DPI (0x2201) 
ratbag raw: hidpp write:  10 ff 00 08 22 01 00
ratbag raw: hidpp read:   11 01 00 08 0c 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x2201 is at 0x0c
ratbag debug: device has adjustable dpi
ratbag raw: hidpp write:  10 ff 0c 08 00 00 00
ratbag raw: hidpp read:   11 01 0c 08 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 0c 18 00 00 00
ratbag raw: hidpp read:   11 01 0c 18 00 00 64 e0 32 64 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 0c 28 00 00 00
ratbag raw: hidpp read:   11 01 0c 28 00 06 40 03 20 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: sensor 0: current dpi: 1600 (default: 800) min: 100 max: 25600 steps: 50
ratbag debug: device is at 1600 dpi (variable between 100 and 25600).
ratbag raw: Init feature 0x1802 (0x1802) 
ratbag raw: hidpp write:  10 ff 00 08 18 02 00
ratbag raw: hidpp read:   11 01 00 08 0d 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1802 is at 0x0d
ratbag raw: Init feature 0x1803 (0x1803) 
ratbag raw: hidpp write:  10 ff 00 08 18 03 00
ratbag raw: hidpp read:   11 01 00 08 0e 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1803 is at 0x0e
ratbag raw: Init feature 0x1805 (0x1805) 
ratbag raw: hidpp write:  10 ff 00 08 18 05 00
ratbag raw: hidpp read:   11 01 00 08 0f 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1805 is at 0x0f
ratbag raw: Init feature 0x1806 (0x1806) 
ratbag raw: hidpp write:  10 ff 00 08 18 06 00
ratbag raw: hidpp read:   11 01 00 08 10 60 04 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1806 is at 0x10
ratbag raw: Init feature 0x1811 (0x1811) 
ratbag raw: hidpp write:  10 ff 00 08 18 11 00
ratbag raw: hidpp read:   11 01 00 08 11 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1811 is at 0x11
ratbag raw: Init feature 0x1830 (0x1830) 
ratbag raw: hidpp write:  10 ff 00 08 18 30 00
ratbag raw: hidpp read:   11 01 00 08 12 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1830 is at 0x12
ratbag raw: Init feature 0x1890 (0x1890) 
ratbag raw: hidpp write:  10 ff 00 08 18 90 00
ratbag raw: hidpp read:   11 01 00 08 13 60 04 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1890 is at 0x13
ratbag raw: Init feature 0x1891 (0x1891) 
ratbag raw: hidpp write:  10 ff 00 08 18 91 00
ratbag raw: hidpp read:   11 01 00 08 14 60 04 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1891 is at 0x14
ratbag raw: Init feature 0x18a1 (0x18a1) 
ratbag raw: hidpp write:  10 ff 00 08 18 a1 00
ratbag raw: hidpp read:   11 01 00 08 15 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x18a1 is at 0x15
ratbag raw: Init feature 0x1801 (0x1801) 
ratbag raw: hidpp write:  10 ff 00 08 18 01 00
ratbag raw: hidpp read:   11 01 00 08 16 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1801 is at 0x16
ratbag raw: Init feature 0x18b1 (0x18b1) 
ratbag raw: hidpp write:  10 ff 00 08 18 b1 00
ratbag raw: hidpp read:   11 01 00 08 17 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x18b1 is at 0x17
ratbag raw: Init feature 0x1df3 (0x1df3) 
ratbag raw: hidpp write:  10 ff 00 08 1d f3 00
ratbag raw: hidpp read:   11 01 00 08 18 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1df3 is at 0x18
ratbag raw: Init feature 0x1e00 (0x1e00) 
ratbag raw: hidpp write:  10 ff 00 08 1e 00 00
ratbag raw: hidpp read:   11 01 00 08 19 40 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1e00 is at 0x19
ratbag raw: Init feature 0x1eb0 (0x1eb0) 
ratbag raw: hidpp write:  10 ff 00 08 1e b0 00
ratbag raw: hidpp read:   11 01 00 08 1a 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1eb0 is at 0x1a
ratbag raw: Init feature 0x1863 (0x1863) 
ratbag raw: hidpp write:  10 ff 00 08 18 63 00
ratbag raw: hidpp read:   11 01 00 08 1b 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1863 is at 0x1b
ratbag raw: Init feature 0x1e22 (0x1e22) 
ratbag raw: hidpp write:  10 ff 00 08 1e 22 00
ratbag raw: hidpp read:   11 01 00 08 1c 60 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x1e22 is at 0x1c
ratbag raw: Init feature 0x2121 (0x2121) 
ratbag raw: hidpp write:  10 ff 00 08 21 21 00
ratbag raw: hidpp read:   11 01 00 08 1d 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: feature 0x2121 is at 0x1d
ratbag raw: unknown feature 0x2121
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 18 00 00 00
ratbag raw: hidpp read:   11 01 07 18 00 00 01 04 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: led_info 0: location: 1 type Logo LED num_effects: 4 persistency_caps: 0x00
ratbag raw: hidpp write:  10 ff 07 18 01 00 00
ratbag raw: hidpp read:   11 01 07 18 01 00 02 04 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: led_info 1: location: 2 type Side LED num_effects: 4 persistency_caps: 0x00
ratbag debug: initializing onboard profiles
ratbag raw: hidpp write:  10 ff 09 08 00 00 00
ratbag raw: hidpp read:   11 01 09 08 01 03 01 05 01 0b 10 00 ff 0a 04 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 09 28 00 00 00
ratbag raw: hidpp read:   11 01 09 28 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag debug: Reading sector 0x0000
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 01 01 00 00 02 00 00 00 03 00 00 00 04 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 10 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 05 00 00 ff ff 00 00 ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 20 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 30 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 40 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 50 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 60 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 70 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 80 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 90 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 a0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 b0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 c0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 d0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 e0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 00 00 ef 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff 1b 6f
ratbag debug: Parsing profile 0
ratbag debug: Reading sector 0x0001
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 02 02 00 90 01 20 03 40 06 80 0c 00 19 ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 10 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff 00 ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 20 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 80 01 00 01 80 01 00 02 80 01 00 04 80 01 00 08
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 30 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 80 01 00 10 80 01 00 04 90 04 00 00 90 03 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 40 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 90 0c 00 00 90 02 00 00 90 01 00 00 ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 50 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 60 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 06 00 00 00 06 00 02 00 06 00 04 00 06 00 06
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 70 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 06 00 08 00 06 00 0a 00 06 00 0c 00 06 00 0e
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 80 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 06 00 10 00 06 00 12 00 06 00 14 ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 90 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 a0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 50 00 52 00 4f 00 46 00 49 00 4c 00 45 00 5f 00
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 b0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 4e 00 41 00 4d 00 45 00 5f 00 44 00 45 00 46 00
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 c0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 41 00 55 00 4c 00 54 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 d0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 01 00 50 50 00 00 00 00 00 00 00 01 00 ff ff 00
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 e0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 00 00 00 00 00 01 00 c2 c2 00 00 00 00 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 01 00 ef 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 00 01 00 ff ff 00 00 00 00 00 00 00 ff 9a 11
ratbag debug: Parsing profile 1
ratbag debug: Reading sector 0x0002
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 01 01 00 90 01 20 03 40 06 80 0c 00 19 ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 10 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff 00 ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 20 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 80 01 00 01 80 01 00 02 80 01 00 04 80 01 00 08
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 30 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 80 01 00 10 90 07 00 00 90 04 00 00 90 03 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 40 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 90 0c 00 00 90 02 00 00 90 01 00 00 ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 50 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 60 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 70 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 80 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 90 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 a0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 b0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 c0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 d0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 03 00 00 00 00 00 1f 40 00 00 00 03 00 00 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 e0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 1f 40 00 00 00 ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 02 00 ef 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff 3e 23
ratbag debug: Parsing profile 2
ratbag debug: Reading sector 0x0003
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 01 01 00 90 01 20 03 40 06 80 0c 00 19 ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 10 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff 00 ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 20 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 80 01 00 01 80 01 00 02 80 01 00 04 80 01 00 08
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 30 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 80 01 00 10 90 07 00 00 90 04 00 00 90 03 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 40 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 90 0c 00 00 90 02 00 00 90 01 00 00 ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 50 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 60 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 70 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 80 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 90 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 a0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 b0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 c0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 d0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 03 00 00 00 00 00 1f 40 00 00 00 03 00 00 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 e0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 1f 40 00 00 00 ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 03 00 ef 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff 3e 23
ratbag debug: Parsing profile 3
ratbag debug: Reading sector 0x0004
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 01 01 00 90 01 20 03 40 06 80 0c 00 19 ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 10 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff 00 ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 20 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 80 01 00 01 80 01 00 02 80 01 00 04 80 01 00 08
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 30 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 80 01 00 10 90 07 00 00 90 04 00 00 90 03 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 40 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 90 0c 00 00 90 02 00 00 90 01 00 00 ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 50 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 60 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 70 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 80 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 90 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 a0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 b0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 c0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 d0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 03 00 00 00 00 00 1f 40 00 00 00 03 00 00 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 e0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 1f 40 00 00 00 ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 04 00 ef 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff 3e 23
ratbag debug: Parsing profile 4
ratbag debug: Reading sector 0x0005
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 01 01 00 90 01 20 03 40 06 80 0c 00 19 ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 10 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff 00 ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 20 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 80 01 00 01 80 01 00 02 80 01 00 04 80 01 00 08
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 30 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 80 01 00 10 90 07 00 00 90 04 00 00 90 03 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 40 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 90 0c 00 00 90 02 00 00 90 01 00 00 ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 50 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 60 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 70 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 80 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 90 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 a0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 b0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 c0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 d0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 03 00 00 00 00 00 1f 40 00 00 00 03 00 00 00 00
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 e0 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 00 1f 40 00 00 00 ff ff ff ff ff ff ff ff ff ff
ratbag raw: hidpp write:  11 ff 09 58 00 05 00 ef 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp read:   11 01 09 58 ff ff ff ff ff ff ff ff ff ff ff ff ff ff 3e 23
ratbag raw: hidpp write:  10 ff 09 48 00 00 00
ratbag raw: hidpp read:   11 01 09 48 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 09 b8 00 00 00
ratbag raw: hidpp read:   11 01 09 b8 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 00 00
ratbag raw: hidpp read:   11 01 07 28 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 01 00
ratbag raw: hidpp read:   11 01 07 28 00 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 02 00
ratbag raw: hidpp read:   11 01 07 28 00 02 00 03 c0 05 03 e8 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 03 00
ratbag raw: hidpp read:   11 01 07 28 00 03 00 0a c1 05 00 3c 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 00 00
ratbag raw: hidpp read:   11 01 07 28 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 01 00
ratbag raw: hidpp read:   11 01 07 28 01 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 02 00
ratbag raw: hidpp read:   11 01 07 28 01 02 00 03 c0 05 03 e8 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 03 00
ratbag raw: hidpp read:   11 01 07 28 01 03 00 0a c1 05 00 3c 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 09 48 00 00 00
ratbag raw: hidpp read:   11 01 09 48 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 00 00
ratbag raw: hidpp read:   11 01 07 28 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 01 00
ratbag raw: hidpp read:   11 01 07 28 00 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 02 00
ratbag raw: hidpp read:   11 01 07 28 00 02 00 03 c0 05 03 e8 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 03 00
ratbag raw: hidpp read:   11 01 07 28 00 03 00 0a c1 05 00 3c 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 00 00
ratbag raw: hidpp read:   11 01 07 28 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 01 00
ratbag raw: hidpp read:   11 01 07 28 01 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 02 00
ratbag raw: hidpp read:   11 01 07 28 01 02 00 03 c0 05 03 e8 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 03 00
ratbag raw: hidpp read:   11 01 07 28 01 03 00 0a c1 05 00 3c 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 09 48 00 00 00
ratbag raw: hidpp read:   11 01 09 48 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 00 00
ratbag raw: hidpp read:   11 01 07 28 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 01 00
ratbag raw: hidpp read:   11 01 07 28 00 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 02 00
ratbag raw: hidpp read:   11 01 07 28 00 02 00 03 c0 05 03 e8 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 03 00
ratbag raw: hidpp read:   11 01 07 28 00 03 00 0a c1 05 00 3c 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 00 00
ratbag raw: hidpp read:   11 01 07 28 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 01 00
ratbag raw: hidpp read:   11 01 07 28 01 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 02 00
ratbag raw: hidpp read:   11 01 07 28 01 02 00 03 c0 05 03 e8 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 03 00
ratbag raw: hidpp read:   11 01 07 28 01 03 00 0a c1 05 00 3c 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 09 48 00 00 00
ratbag raw: hidpp read:   11 01 09 48 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 00 00
ratbag raw: hidpp read:   11 01 07 28 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 01 00
ratbag raw: hidpp read:   11 01 07 28 00 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 02 00
ratbag raw: hidpp read:   11 01 07 28 00 02 00 03 c0 05 03 e8 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 03 00
ratbag raw: hidpp read:   11 01 07 28 00 03 00 0a c1 05 00 3c 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 00 00
ratbag raw: hidpp read:   11 01 07 28 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 01 00
ratbag raw: hidpp read:   11 01 07 28 01 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 02 00
ratbag raw: hidpp read:   11 01 07 28 01 02 00 03 c0 05 03 e8 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 03 00
ratbag raw: hidpp read:   11 01 07 28 01 03 00 0a c1 05 00 3c 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 09 48 00 00 00
ratbag raw: hidpp read:   11 01 09 48 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 00 00
ratbag raw: hidpp read:   11 01 07 28 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 01 00
ratbag raw: hidpp read:   11 01 07 28 00 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 02 00
ratbag raw: hidpp read:   11 01 07 28 00 02 00 03 c0 05 03 e8 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 00 03 00
ratbag raw: hidpp read:   11 01 07 28 00 03 00 0a c1 05 00 3c 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 08 00 00 00
ratbag raw: hidpp read:   11 01 07 08 02 00 03 00 04 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 00 00
ratbag raw: hidpp read:   11 01 07 28 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 01 00
ratbag raw: hidpp read:   11 01 07 28 01 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 02 00
ratbag raw: hidpp read:   11 01 07 28 01 02 00 03 c0 05 03 e8 00 00 00 00 00 00 00 00
ratbag raw: hidpp write:  10 ff 07 28 01 03 00
ratbag raw: hidpp read:   11 01 07 28 01 03 00 0a c1 05 00 3c 00 00 00 00 00 00 00 00
ratbag debug: driver match found: Logitech HID++2.0
hidraw6: "Logitech G502", 5 profiles
ratbag debug: New device: Logitech USB Receiver
ratbag debug: Using data directory '/usr/share/libratbag'
ratbag debug: No data file found for 046d:c539
ratbag debug: New device: Logitech USB Receiver
ratbag debug: Using data directory '/usr/share/libratbag'
ratbag debug: No data file found for 046d:c541
ratbag debug: New device: Logitech USB Receiver
ratbag debug: Using data directory '/usr/share/libratbag'
ratbag debug: No data file found for 046d:c541
ratbag debug: New device: Logitech USB Receiver
ratbag debug: Using data directory '/usr/share/libratbag'
ratbag debug: No data file found for 046d:c541
ratbag debug: New device: Sennheiser Sennheiser 3D G4ME1
ratbag debug: Using data directory '/usr/share/libratbag'
ratbag debug: No data file found for 1395:1000
DBus server ready

</details>

TimDiekmann

comment created time in 2 months

issue openedlibratbag/libratbag

Logitech G502 and G915 DeviceMatch missing

Information <!-- If your issue is related to a Logitech device please make sure you are running at least Linux 5.2 -->

  • ratbagd version (ratbagd --version): 0.14
  • Distribution: Arch Linux
  • Kernel version (ex. uname -srmo): Linux 5.7.12-arch1-1 x86_64 GNU/Linux

I have plugged in the logitech G502 Mice and the G915 keyboard. In the data/devices list, both devices are listed but have the wrong DeviceMatch. When adding the usb information to the match, they are recognized. Is this a bug or may I have to make a PR to add those addresses?

logitech-g502-hero-wireless.device:

-DeviceMatch=usb:046d:407f;usb:046d:c08d
+DeviceMatch=usb:046d:407f;usb:046d:c08d;usb:046d:c539

logitech-g915.device:

-DeviceMatch=usb:046d:c33e
+DeviceMatch=usb:046d:c33e;usb:046d:c541

created time in 2 months

push eventTimDiekmann/alloc-wg

TimDiekmann

commit sha b765af85f8ddf9583ce0696db82b3c333acc057a

Automated deployment: Fri Aug 28 01:36:07 UTC 2020 4acb3d9be1614f28f2a40d8c1a81341771413f83

view details

push time in 2 months

delete branch TimDiekmann/alloc-wg

delete branch : TimDiekmann-patch-1

delete time in 2 months

push eventTimDiekmann/alloc-wg

Tim Diekmann

commit sha 9946af6a7500fd06f8fb8f7853c3ca6aa957b231

Update raw_vec.rs

view details

Tim Diekmann

commit sha 4acb3d9be1614f28f2a40d8c1a81341771413f83

Merge pull request #24 from TimDiekmann/TimDiekmann-patch-1 Update raw_vec.rs

view details

push time in 2 months

more