What dictates the shape of the attitude indicator display on the PFD? I notice the atitude indicator displayed in the PFD is either squared-shape or truncated-circle-shaped.

A good example of the square shape is the B747-400, It looks like a square whose corner are a bit rounded:


(Source: airliners.net)

A good example of the circle-shaped is the SAAB2000 or the A340:


(Sources: airliners.net and airliners.net)

They look like a circle whose both right and left sides are truncated to display rules (speed and altitude).

In either case, the information displayed are the same (pitch, bank angle, perhaps flight director,...) and are displayed in a very similar manner (including the colors). Those 2 designs exists for years, so there may not be advantages of one over the other.  Why one is preferred over the other for some manufacturer, and the other one for other manufacturer? What criteria are taken into account when choosing this shape?
A circle makes sense because a physical attitude indicator is round. (A physical one has to be round because it consists of a ball moving behind a window.) It makes the screen display look more like the instrument it replaces, which is good for recognition and familiarity, and makes it easier to judge things like bank angles.

A rectangle makes sense because it has to fit on a rectangular screen. You can tile rectangular instruments/displays on a screen efficiently, with no wasted space between them, as your example shows with the tapes. Rounding the corners delineates the edges of the display better than just having abutting rectangles.

The full process by which physical cockpit instruments and glass-cockpit displays are designed and laid out is too long to explain here. The main focus is on making it hard to make mistakes, and after that to make it quick to see the most important information. To support this, each instrument has to be easy to identify and to read correctly. Despite the shape difference, the two designs look very similar. Even if you've never flown any of these aircraft before, you'd immediately recognise it as an attitude indicator, and you wouldn't confuse it with a different instrument.