Skip to content
This repository has been archived by the owner on Sep 20, 2023. It is now read-only.

allwinner and bcm283x: Add FastOut() #175

Closed
maruel opened this issue Dec 10, 2017 · 1 comment
Closed

allwinner and bcm283x: Add FastOut() #175

maruel opened this issue Dec 10, 2017 · 1 comment

Comments

@maruel
Copy link
Contributor

maruel commented Dec 10, 2017

The function would be:

FastOut(l gpio.Level)

with no error. It will be extracted code in Out() without the error checking. Out() will call into this function after error checking. For example for bcm283x, it would be the 5 lines affecting gpioMemory.outputClear and gpioMemory.outputSet.

No interface would be created for in, to hinder anti-pattern of using an interface here, as the end goal is to make the code as close to bare metal as possible. Coupled with issue #174, the code could be completely inlined at call site.

maruel added a commit that referenced this issue Dec 10, 2017
Add benchmarks to see the performance difference.

Fixes #175
maruel added a commit that referenced this issue Dec 10, 2017
Add benchmarks to see the performance difference.

Fixes #175
maruel added a commit that referenced this issue Dec 10, 2017
Add benchmarks to see the performance difference.

Fixes #175
@maruel
Copy link
Contributor Author

maruel commented Dec 12, 2017

Was fixed in ee4d184 and 104d587.

@maruel maruel closed this as completed Dec 12, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant