Skip to content

Add C++ Template Code#1

Open
buszk wants to merge 3 commits into
gavra0:masterfrom
buszk:cpp-pr
Open

Add C++ Template Code#1
buszk wants to merge 3 commits into
gavra0:masterfrom
buszk:cpp-pr

Conversation

@buszk
Copy link
Copy Markdown

@buszk buszk commented Nov 20, 2019

I implemented a version using the C++ template.

In this version, a llist<int32_t, INT_MIN, INT_MAX> is the lock-free list of int32_t type.

The only caveat I see is the code run ~10x slower. The overhead is due to C++ infrastructure(I guess?), not template or class. I am pretty sure this can be optimized somehow. I am just not very experienced with it.

@buszk
Copy link
Copy Markdown
Author

buszk commented Nov 20, 2019

The performance with cpp-template code isn't bad at all. Must be some problem on my side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant