Remove tagged pointer example

This commit is contained in:
Yota Toyama
2023-09-28 12:26:49 +10:00
parent 2e9a216f28
commit a318362d25
3 changed files with 0 additions and 31 deletions

View File

@@ -5,5 +5,4 @@ members = [
"free_by_borrow", "free_by_borrow",
"free_by_gc", "free_by_gc",
"static_threads", "static_threads",
"tagged_pointer",
] ]

View File

@@ -1,9 +0,0 @@
[package]
name = "tagged_pointer"
version = "0.1.0"
authors = ["Yota Toyama <raviqqe@gmail.com>"]
edition = "2021"
publish = false
[dependencies]
bdwgc-alloc = { path = "../.." }

View File

@@ -1,21 +0,0 @@
extern crate bdwgc_alloc;
use bdwgc_alloc::Allocator;
use std::alloc::Layout;
#[global_allocator]
static GLOBAL_ALLOCATOR: Allocator = Allocator;
fn main() {
unsafe { Allocator::initialize() }
let handle = std::thread::spawn(move || {
unsafe { Allocator::register_current_thread().unwrap() }
loop {
let _ = unsafe { std::alloc::alloc(Layout::from_size_align(2 ^ 8, 8).unwrap()) };
}
});
handle.join().unwrap();
}