Fork me on GitHub

Thursday, December 17, 2009

Reborn a Princess?

A Roller Coaster Wridden by the Mad Hatter Jason

With clear vantage he stands upon the mount,
atop the apex of his being, surveying things one can't count.
The valleys down below echo in chorus
telling grand stories with messages amorous
and tales of nearing epoch on his account.
Observantly, he sits in wait, ever curious
listening for the hints his future may recount.

With battlefield ballads of heart mind and soul,
intermixing melodies of each of his goals.
All well defined, he's in complete control
yet stagnant he waits, debating his role.
Two melodies at war with none to console
and a third sonorously resonating; amplifying the whole.

His empire is forming, of this he is sure,
yet he takes no claim 'til his aims be secure.
Seeking solace in heart with expression that's pure,
slows the acquisition of success for this entrepreneur.
All the while fulfilling potential could be the cure,
but should he be satisfied trailing money as his spoor
or ensure his pursuit is not drawn by this allure.

His potential laid before him, illusory confusion disbanded;
his castle's not built yet and so he must move forward.
Yet in timely fashion, significance of other tunes expanded
the melodious infusion becomes less obscure yet carries no reward.
Instead he listens to lonely tones, once again standing stranded.

Alas, music to his ears, the notes begin to harmonize.
Finally a path appears wherein a symphony might form,
in front of him doth his heart's song materialize
such radiantly burning melody with no care for the norm;
peering past words he doesn't intend to idealize
but rather knows full well that he seeks the perfect storm
if only the efforts of happiness would make her realize.

He observes as her journey takes the fashion like Ulalume,
veiled like a raven beguiling her sad fancy into smiling,
as she again unknowingly travels to her lost love's tomb
and he hopes that her off-putting words are of like styling.

Reinforcing stone walled heart with her soul's intense fire,
she's managed to postpone his last sought desire;
though she shields her cloaked heart, his thoughts do not tire
instead against her voiced motive, the challenge doth inspire.
He can't help but notice melodic lines from her luminous lyre;
the tonal pattern of a child's pure joy that elates the young sire
empowering him to withstand her psyche's blazing pyre.

Crazy love shrouds him as burnt landscape doth form
and when the dance gets hot he does not hide or mourn.
He simply waits wishing for the honor to see the phoenix reborn

Thursday, August 27, 2009

Mimsy's Box

A mental delicacy prepared in race fashion by none other than the Mad Hatter Jason.

She pierces him with eyes of fire,
Revs her engine and spins her tires,
In hot pursuit he chases her,
Finding her lines, each hidden curve,
He gently follows her snaking path,
Learning more at every pass.
All is fun and the race goes fast,
When suddenly his chase doth crash!

An earth-shaking tremor of doubt,
Second guesses run rampantly,
Guiding a guilt-based inner bout,
He worries about her safety,
But next thing he knows she starts to burn out.

Again he gives chase
To see her pretty face
But down the road discovers
This time’s not a race.
She flees the scene to keep him safe
And frees the man from awful fate
But thinks not how his heart might shake
‘Til face to face they meet beside a lake.

He reads the surface of her mind,
Proving out loud that it’s clear as day,
But when he wonders what he’ll find,
When digging deeper, and what she’ll say.
In the realm of sanity,
He starts to play,
With words like a hatter,
His madness on display.

Down the rabbit hole he lives,
Beckoning her further so he might give
Insight of healing and thoughts curative.
A young Alice, she wavers at the small door,
To a world that is meaningless and yet means so much more.
Unmoving she stands debating the vial,
Wondering how insanity will help her survival.

And thus the hatter speaks,
Explaining his world,
Describing what he sees,
The girl’s being unfurled.

"An angel stuffed in a box labeled 'DO NOT OPEN. EVIL' guarded by a selfish girl shrouded in a thin cloak of innocence imagining a dark cloud of guilt overhead."

He says, then details what he wants instead.
Why oh why, won’t you be nicer to yourself and me,
I can’t wait to see inside Mimsy.
Around the question the rabbit dances,
With no meaning given, a short reply she answers
Smiling she prances "Uhuh... we’ll see."
Seeing her fence, he lures her in
To break her defense of the question
He simply states rather exactly
I’m not sure you know what’s in the box, my dear mimsy.
In playful response she takes the poke,
Inside the box? Hmm… nope
Well milady Mimsy, what remains is called "Hope."

Not wanting to hurt, or be hurt in kind,
She ignores his advances time after time.
She says she needs easiness (so she can drive blind),
But he knows it’s a challenge that will make her sublime.
Discussing Pandora and history past,
He tells her of differences between the easy and right paths.
Alas, if only Mimsy were the Borogoves,
And the past would find its tears,
The hatter could hap happiness,
And destroy all her fears.

The psycho semantic and curious chef,
To the best of his skills with which he’s been blessed
He composes tenuously a meal of mental obscurity,
With such delicious components, an epicurean rarity
And simplistic appearance on which she can dine
Where the residual flavor improves over time.
Finally she opens her heart to his mind,
Even if only a piece at a time,
Alas his chance has finally arrived,
To be such a happy Mad Hatter that he composes this rhyme.



This is a poem I wrote not long ago. I'm very pleased with the way it turned out (the poem, not so much the rest of the story, lol) and have kept it quietly stashed amongst close friends, but I'm so very fond of this poem and have little reason to keep it locked up, so I thought I would share it with the world. There are many reason's I'm happy with this work, some which will not be perceived by anybody, some that only a select few will understand, but for the rest of you, I'm quite happy with two things primarily: First, I wrote this from beginning to end with no backtracking, proof reading or editing (Edit: I added the subtitle when I finished). Second, is my application of the term "mimsy," originally coined by the great author Charles Lutwidge Dodgson (better known as Lewis Carroll), whom I have a great deal of respect and admiration of. Mimsy, in this work, is a person to whom, at the time in my mind's eye, both Carroll's initial meaning of the word, as well as the additional meaning and context added over the years. At any rate, do enjoy. I'm interested in feedback too, though it's unlikely that I will edit the work at all, considering the circumstances.

Friday, August 7, 2009

TechVi: Zune Development with XNA

First and foremost, I want to thank the gents over at TechVi for inviting me to contribute to their program. It's always nice to work with a bunch of smart and driven folks. That said, as I just came on board today I was going through some of the previous shows to see what I was getting into. As I was taking a peak at the recent ZuneHD spot some comparison between the iPod Touch/iPhone caught my attention with the mention of application development on the Zune, which came across as a rather bleak outlook. I just wanted to point out some of the things Microsoft has been working on to that regard to give a little more clarity.

To be clear, I'm no expert with the Zune (my Touch Pro is a perfectly sufficient MP3 player for me), nor am I personally up to date with the development technologies I'll be pointing out. I have, however, been watching Microsoft's strategy for many years as they've moved forward and I have my own hypothesis to make about the future of development in this regard. Now, to the point:

Over the last few years Microsoft's .NET Framework has been gaining a lot of ground in the development industry. One of it's challenges early on was that, while well designed for desktop and web applications, it was not prepared for one of the most sought after markets in the technology industry: games. Those of us who were knee deep in trying to figure out ways to make good games while still leveraging the power of .NET during these early days may even remember Microsoft releasing an unsupported Managed wrapper for DirectX with the DirectX SDK. Not long after (but long enough for plenty of us to have started dabbling with it) they yanked the good stuff right out from under us. Turns out Microsoft was moving to a new platform altogether. Enter XNA (the clever buggers went and took the recursive acronym to a new level, XNA stands for "XNA is Not an Acronym"). It started a bit rough, but, as with any other Microsoft development technology, ultimately turned out to be generally viewed as really well planned with great tools and a lot of opportunity ahead.

Since it's mention in 2004, XNA Game Studio is up to version 3 and now offers 2D and 3D game development support and runs, in some capacity or another, on Desktop PCs, XBOX 360, and Zune. The platform is based on a modified version of the .NET Compact Framework which is a reasonably capable and very easy to use development platform that facilitates a powerful, easy to read/write, well organized environment. Using this technology it is possible to develop a game that will run on all three platforms with little to no change in the code. In order to leverage this to compete with Apple's App Store it may be necessary for Microsoft to rethink their distribution model (currently they offer a paid subscription only designed for XBOX 360), but as a development platform it is very clean, easy to use and powerful.

I don't know what Microsoft intends to do about distribution, but I can at least speculate on one more change that seems innevitable for the future. Early on the intention to support Windows Mobile devices with XNA alongside the XBOX and Desktop PC seemed obvious, though over time have faded from memory. Zune managed to get in the door first, but I still see the handheld OS now commonly found on phones in XNA's near future. I've been toying with Windows Mobile 6.5 and an unreleased version of the NetCF runtime (listed currently as version 3.7). One of the first things I noticed while playing with the new runtime is that it no longer includes the mobile Managed DirectX library. Some speculate that it's because OpenGLES is so dominant in the portable industry, but this feels rather reminiscent of the last time they wanted to make a move to XNA. The Windows Mobile platform will be much harder to target than XBOX and Zune were because of the great variety of hardware that it runs on and their varying capabilities (much like the desktop version), but since XNA is based on the Compact Framework it seems like an innevitable move, leaving the bulk of my assumption on the "when" side. I guess now all we can do is wait and see.

Monday, April 6, 2009

Retry Oriented Thread Synchronization

Somewhat recently at work I've been troubleshooting some concurrency edge cases involving deadlocks due to thread synchronization. In my experience, a lot of times this is the result of creating lock objects for separate collections or something of the sort. In most of the code only one collection/object is accessed at a time and the separate synchronization objects allow for less contention and more throughput. Excluding simple/obvious mistakes, the problem typically arises when different code paths require the objects in opposite order, sometimes becoming more difficult to trace when they involve events/handlers. Obviously on goal when locking is to lock the synchronization object for as little time as possible, but sometimes it's simply necessary to hold a lock while entering an event or callback.

One solution, which worked fine for us, was to get rid of one of the synchronization objects and use the same one for both collections. Ultimately it was all that was necessary for our solution, since we couldn't change the other code paths or unlock one of the synchronization roots, but it did inspire me to start trying to think of a better solution. I've been toying with an idea somewhat similar to the pattern used by TransactionScope, taking advantage of the using statement to allow syntax to stay simple (since the lock statement is so lightweight it would be ideal to keep the new solution quick and easy). I certainly haven't found the ideal solution just yet, and it's quite likely that there really is no ideal solution, but I've posted the new code and test application on CodePlex, hoping others in the community will see the potential advantages and help me improve on it, either with code or ideas. This also doesn't implement any synchronization techniques regarding Mutexes, Semaphores, or any other wait handle style synchronization, this is currently specific to using Monitor and may only serve to improve circumstances using traditional lock statements or Monitor directly.

The general concept behind usage in the current implementation is as follows:

using (LoopLock l = new LoopLock(ltp.Syncs))
{
//optional event, but here for testing
l.LockAttemptFailed += new LoopLockEventHandler(delegate(LoopLock sender, LoopLockEventArgs e)
{
if (e.Attempts > 200)
{
//sample of aborting if it takes to long to get a successful lock;
e.AbortLock();
}
});

l.AcquireLock();

Thread.Sleep(rnd.Next(5490) + 20);

}
The LoopLock constructor takes in a params array of all the synchronization objects (in the order they should be locked). The AcquireLock method only exists to allow attaching an event handler, which will be described in a moment. AcquireLock attempts to obtain a lock on each synchronization object one at a time. If it is unable to obtain any lock in 100ms (by default, though there is a constructor overload to provide the timeout period) it will proceed to unlock each of the successfully locked objects (in reverse order), fire the LockAttemptFailed event which provides the number of tries so far along with the option of aborting the process alltogether (which throws a LoopLockAbortedException). If all locks are acquired code will proceed and, when the code leaves the scope of the using statement, all locks are released (in the opposite order they were locked).

One thing I've already considered through the simple test application I've made is the possibility of adding support for prioritization based on retry counts, which could be useful, but since these are thread specific and this is supposed to be a lightweight class it may require the use of WeakReferences so I haven't gone through with it yet since I'm still working on finding other possibilities and it could wind up being a waste of effort. One problem mentioned above that this still doesn't solve is the event handler situation, where I lock a synchronization object important to me and then fire an event which can be attached to by arbitrary code; since I don't have control over both code-bases I can't see a means to provide any "let me get out of your way" logic, since we can't release the lock once synchronization-dependent code has already begun executing. I was thinking about the possibility of a delegate or delegate wrapper that carries a reference to the synchronization object would work for some occasions, but without some under-.NET's-hood voodoo it would still sacrifice syntax clarity/diversity, which I'm trying to avoid. It seems there will have to be a tradeoff somewhere in order to improve this model, and maybe using a single callback with a synchronization object reference instead of supporting a multicast delegate may be that answer, but for now I'm going to think on it more. I would really love any insight from those in the wilderness; I've certainly not been exposed to every method of using threads and synchronization and, while I'm pretty familiar with Monitor and other synchronization classes, there could still be something obvious I'm not privy too as well.

-TheXenocide

Saturday, January 10, 2009

Selective Interpretation

Well, I haven't posted in forever, and this isn't what I was shooting for, but I went on another rant in some forums related to "The Boondocks" animated TV series so I figured I'd post it here. Fragile readers beware, this is a serious and potentially controversial topic. You don't have to agree with me, but this is my little brain dump and I'd like to let others read it. If you have a sufficient argument (with some intellect behind it) feel free to debate, but here goes:

Anybody who sets or adheres to a policy that one race can do something and another can't (like say "the n word") is a racist.

I don't consider it important to mention what "color" or "race" I am, but suffice it to say that I've lived (throughout several states) in "the projects", inner city, suburbs, "redneck" country, been homeless, lived in a 3 bedroom house on an estate by the water and more. In the projects and city I said "the n word" and was called "the n word" on a daily basis and it didn't mean a thing until I moved somewhere else and experienced people selectively interpreting the term as offensive. I've seen different "rules" about who can and can't say it in every different place I've lived (even ones like "n*gga" is different from "n*gger" and places that say Latinos and South Americans are qualified; did you know the English have used it to refer to the Irish?). I understand full well the history and the connotation of the word, but as it stands today it's not about the word, it's about the intention.

If someone wants to be offensive it doesn't matter what words they use, they're going to be perceived as offensive. If someone wants to be offended, it doesn't matter what the circumstance is, they will find something to be offended about. Some people strive for drama (like people who react every time a non-"black" *person* says it) and some people are afraid of it (like people who aren't racist but are afraid to say the word because they figure people will think they are) but, ultimately, all of these responses are just giving power to something that is nothing more than a word. If I say sh*t or f**k today most people will just think it's normal or maybe somewhat irresponsible, but there was a point in time when it was very offensive (the term "curse words" comes from the idea that people would literally be cursed for using them; clearly they weren't and people realized it and moved on). What changed? The words didn't; only the mentality did. Just the same, people also say "bless you" because at some point people thought that sneezing expelled the soul from the body and that "blessing someone" would somehow put it back in or protect them.

We set the standards by living them, so you can support racism by taking a racist stance (like one person can say something that another can't) or you can move on and live your life like nobody is different which will (even if only slowly) change the general mentality and (hopefully) abolish racism/sexism/*ism. Remember that freedom is the right to do whatever you want so long as you don't affect someone else's right to do what they want.

We learn new things every day and the thing that holds us back more than anything are the people who refuse to move forward. Grow up, help mankind, and get over yourself and the past to work for a better future. Cracker, Wap, Porch-Monkey (somebody! quick! take it back! ;p), Spic, whatever: it doesn't matter unless you let it. We can't change the past; no word will ever be eliminated, sometimes most people just stop using it. Then again I'm being a bit loquacious, which is a word that is hardly ever used today (though I did wind up using it the other day), but it's still available when someone (like myself) wants it.

Who's to say any culture is "ours" or "yours" or anyone else's for that matter?! Ethnicity isn't about race (scroll down); it's about shared experiences and learning, much more frequently associated with location and is sometimes associated with a minority group, but only in a more recent and selective definition which also requires you to interpret religion in the same boat (anybody have any preconceptions about Muslims?). People appreciate and learn new cultures; the people that made Adult Swim what it is were appreciating Japanese culture and then it slowly became that of the "nerd" which the majority of were smart enough to appreciate anything made with some sort of intellect and humor (like "The Boondocks"). In any given week I eat food from at least 5 different cultures, including the "American" culture which has basically been a very recently evolved combination of many other cultures. Ultimately there are people who are trying to pretend they're something they're not so that people will see them a certain way ("cool" perhaps?) which, no matter whether it be "black" culture or the "popular" clique, always stand out as idiots who aren't confident or happy enough with themselves to be real. Anybody that makes "exceptions" to these racist institutions does so on the basis that someone is being "real" as opposed to being a "poser." You can pretend they're all different situations if you want, but you're selectively interpreting things to make your own life easier so you don't have to learn and evolve your own perspective. People want everyone else to see the world the way they do (subjectively) instead of trying to look at the world objectively and learning about their own inaccuracy. "Black" "Hip-hop culture" isn't even remotely close to what it was 10 years ago, let alone like the "black culture" of slavery or Jim-Crow-era post-slavery; cultures grow and evolve as people interact and move from one to another. Check the British Lady Sovereign et al on "The Battle" and you'll catch a completely different infusion of cultures made by people of multiple "races" - it doesn't matter what color they are or where they're from. Once you get past the accent you have to admit they spit real fire.

I'm seriously concerned about how many people look at this topic without ever taking a step back and looking at the big picture. With any luck the world will now be a better place; thanks for your time if you made it through all this.

Be real (Aaron McGruder would be),

-TheXenocide