-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Removal of objc source, addition of assembly source.
- Loading branch information
RJ Ross
committed
Mar 31, 2014
1 parent
f4e3728
commit a31a7ab
Showing
19 changed files
with
1,173 additions
and
409 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
## An iOS App In Assembly | ||
|
||
It's just what it sounds like. Hand written, delicately debugged, well-commented, ARMv7 assembly. Work on this started before ARM64 devices were a thing, so support for them may come in the future. | ||
|
||
### Goals | ||
|
||
Rather simple, make an app that compiles, runs, and draws somthing on the screen, using only hand written assembly. The only times I used the assembly output of clang was to determine the proper `.section`s for things, to let lldb be able to debug my functions. | ||
|
||
The basic structure of this app is based on my [iOS App In Pure C](https://github.com/richardjrossiii/CBasediOSApp), with a 'main' file which contains all the set-up code, and two supporting files, for each of the classes (AppDelegate, and View). | ||
|
||
The drawing code is all done using CoreGraphics, and displays the string 'Hello, Assembly!' in red on the screen. Here's a screenshot of the app running on my iPhone 5S: | ||
|
||
![](http://i.imgur.com/mulfx8nl.png) | ||
|
||
### Notes | ||
|
||
If running the app with any accessiblity features enabled (switch control, guided access, etc.) the app crashes when the runtime tries to see if my App Delegate responds to the selector `accessibilityInitialize`, and I'm not entirely sure why. This may be fixed in the future. | ||
|
||
### Resources | ||
|
||
- [Apple's iOS ABI Reference](https://developer.apple.com/library/ios/documentation/Xcode/Conceptual/iPhoneOSABIReference/Introduction/Introduction.html#//apple_ref/doc/uid/TP40009020-SW1) | ||
- [The ARM ABI Reference](http://infocenter.arm.com/help/topic/com.arm.doc.subset.swdev.abi/index.html) | ||
- [The ARM Developer Suite Assembler Guide](http://infocenter.arm.com/help/topic/com.arm.doc.dui0068b/index.html) | ||
|
||
And, as always, the mighty power of Google. |
Large diffs are not rendered by default.
Oops, something went wrong.
10 changes: 10 additions & 0 deletions
10
...deproj/project.xcworkspace/xcuserdata/angrybeast.xcuserdatad/WorkspaceSettings.xcsettings
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<dict> | ||
<key>HasAskedToTakeAutomaticSnapshotBeforeSignificantChanges</key> | ||
<true/> | ||
<key>SnapshotAutomaticallyBeforeSignificantChanges</key> | ||
<false/> | ||
</dict> | ||
</plist> |
12 changes: 12 additions & 0 deletions
12
...oj/project.xcworkspace/xcuserdata/angrybeast.xcuserdatad/xcdebugger/Expressions.xcexplist
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<VariablesViewState | ||
version = "1.0"> | ||
<ContextStates> | ||
<ContextState | ||
contextName = "View_DrawRect:(null)"> | ||
</ContextState> | ||
<ContextState | ||
contextName = "-[NSObject respondsToSelector:]:(null)"> | ||
</ContextState> | ||
</ContextStates> | ||
</VariablesViewState> |
5 changes: 5 additions & 0 deletions
5
...Assembly.xcodeproj/xcuserdata/angrybeast.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<Bucket | ||
type = "1" | ||
version = "2.0"> | ||
</Bucket> |
2 changes: 1 addition & 1 deletion
2
...nAssembly.xcodeproj/xcuserdata/angrybeast.xcuserdatad/xcschemes/iOSAppInAssembly.xcscheme
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.