diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp
index cfa3f4ae022e39b41829fe23312a029855598ecc..574b449d239eb45139912159ff45dfb80b2b025d 100644
--- a/indra/newview/llagentwearables.cpp
+++ b/indra/newview/llagentwearables.cpp
@@ -675,7 +675,7 @@ void LLAgentWearables::setWearable(const EWearableType type, U32 index, LLWearab
 	{
 		wearable_vec[index] = wearable;
 		old_wearable->setLabelUpdated();
-		mAvatarObject->wearableUpdated(wearable->getType());
+		wearableUpdated(wearable);
 	}
 }
 
@@ -690,13 +690,32 @@ U32 LLAgentWearables::pushWearable(const EWearableType type, LLWearable *wearabl
 	if (type < WT_COUNT || mWearableDatas[type].size() < MAX_WEARABLES_PER_TYPE)
 	{
 		mWearableDatas[type].push_back(wearable);
-		mAvatarObject->wearableUpdated(wearable->getType());
-		wearable->setLabelUpdated();
+		wearableUpdated(wearable);
 		return mWearableDatas[type].size()-1;
 	}
 	return MAX_WEARABLES_PER_TYPE;
 }
 
+void LLAgentWearables::wearableUpdated(LLWearable *wearable)
+{
+	mAvatarObject->wearableUpdated(wearable->getType());
+	wearable->setLabelUpdated();
+
+	// Hack pt 2. If the wearable we just loaded has definition version 24,
+	// then force a re-save of this wearable after slamming the version number to 22.
+	// This number was incorrectly incremented for internal builds before release, and
+	// this fix will ensure that the affected wearables are re-saved with the right version number.
+	// the versions themselves are compatible. This code can be removed before release.
+	if( wearable->getDefinitionVersion() == 24 )
+	{
+		wearable->setDefinitionVersion(22);
+		U32 index = getWearableIndex(wearable);
+		llinfos << "forcing werable type " << wearable->getType() << " to version 22 from 24" << llendl;
+		saveWearable(wearable->getType(),index,TRUE);
+	}
+
+}
+
 void LLAgentWearables::popWearable(LLWearable *wearable)
 {
 	if (wearable == NULL)
diff --git a/indra/newview/llagentwearables.h b/indra/newview/llagentwearables.h
index 8f3a16501e12b11e3398e7b54c9c779665041eaa..b4f58674af3aff31d8f6ef64a9d6580d6470f17c 100644
--- a/indra/newview/llagentwearables.h
+++ b/indra/newview/llagentwearables.h
@@ -107,6 +107,7 @@ class LLAgentWearables
 	// Low-level data structure setter - public access is via setWearableItem, etc.
 	void 			setWearable(const EWearableType type, U32 index, LLWearable *wearable);
 	U32 			pushWearable(const EWearableType type, LLWearable *wearable);
+	void			wearableUpdated(LLWearable *wearable);
 	void 			popWearable(LLWearable *wearable);
 	void			popWearable(const EWearableType type, U32 index);
 	
diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp
index 0844cca766283a6f3c30bf3b4b8f294d70a30cf6..89a774fd2bd3f41f70762c20096aaa55e07ed732 100644
--- a/indra/newview/llavataractions.cpp
+++ b/indra/newview/llavataractions.cpp
@@ -324,6 +324,27 @@ void LLAvatarActions::pay(const LLUUID& id)
 	}
 }
 
+//static 
+void LLAvatarActions::share(const LLUUID& id)
+{
+	LLSD key;
+	LLSideTray::getInstance()->showPanel("sidepanel_inventory", key);
+
+
+	LLUUID session_id = gIMMgr->computeSessionID(IM_NOTHING_SPECIAL,id);
+
+	if (!gIMMgr->hasSession(session_id))
+	{
+		startIM(id);
+	}
+
+	if (gIMMgr->hasSession(session_id))
+	{
+		// we should always get here, but check to verify anyways
+		LLIMModel::getInstance()->addMessage(session_id, SYSTEM_FROM, LLUUID::null, LLTrans::getString("share_alert"), false);
+	}
+}
+
 // static
 void LLAvatarActions::toggleBlock(const LLUUID& id)
 {
diff --git a/indra/newview/llavataractions.h b/indra/newview/llavataractions.h
index d9dab95a77016e540f61bdd45f7a4ae7a557d2db..4c9851a48d4fde4a54b196534e3527ad3418ef48 100644
--- a/indra/newview/llavataractions.h
+++ b/indra/newview/llavataractions.h
@@ -103,6 +103,11 @@ class LLAvatarActions
 	 */
 	static void pay(const LLUUID& id);
 
+	/**
+	 * Share items with the avatar.
+	 */
+	static void share(const LLUUID& id);
+
 	/**
 	 * Block/unblock the avatar.
 	 */
diff --git a/indra/newview/llfloatertools.cpp b/indra/newview/llfloatertools.cpp
index 9854d2594b2a30111e7cf3be5a81d80f8f434140..b4d248bc40b98e08882f3f3a18d61fe771cdaae0 100644
--- a/indra/newview/llfloatertools.cpp
+++ b/indra/newview/llfloatertools.cpp
@@ -563,7 +563,8 @@ void LLFloaterTools::updatePopup(LLCoordGL center, MASK mask)
 
 	mBtnEdit	->setToggleState( edit_visible );
 	mRadioGroupEdit->setVisible( edit_visible );
-	childSetVisible("RenderingCost", edit_visible || focus_visible || move_visible);
+	bool linked_parts = gSavedSettings.getBOOL("EditLinkedParts");
+	childSetVisible("RenderingCost", !linked_parts && (edit_visible || focus_visible || move_visible));
 
 	if (mCheckSelectIndividual)
 	{
@@ -975,6 +976,8 @@ void LLFloaterTools::onClickGridOptions()
 S32 LLFloaterTools::calcRenderCost()
 {
 	S32 cost = 0;
+	std::set<LLUUID> textures;
+
 	for (LLObjectSelection::iterator selection_iter = LLSelectMgr::getInstance()->getSelection()->begin();
 		  selection_iter != LLSelectMgr::getInstance()->getSelection()->end();
 		  ++selection_iter)
@@ -985,11 +988,14 @@ S32 LLFloaterTools::calcRenderCost()
 			LLVOVolume *viewer_volume = (LLVOVolume*)select_node->getObject();
 			if (viewer_volume)
 			{
-				cost += viewer_volume->getRenderCost();
+				cost += viewer_volume->getRenderCost(textures);
+				cost += textures.size() * 5;
+				textures.clear();
 			}
 		}
 	}
 
+
 	return cost;
 }
 
diff --git a/indra/newview/llpanelavatar.cpp b/indra/newview/llpanelavatar.cpp
index 2254684f2150c9ae3bb7090739df9f13e961240e..a822897c7e644bff821f9ef33ba94438753b1754 100644
--- a/indra/newview/llpanelavatar.cpp
+++ b/indra/newview/llpanelavatar.cpp
@@ -339,6 +339,7 @@ BOOL LLPanelAvatarProfile::postBuild()
 
 	LLUICtrl::CommitCallbackRegistry::ScopedRegistrar registrar;
 	registrar.add("Profile.Pay",  boost::bind(&LLPanelAvatarProfile::pay, this));
+	registrar.add("Profile.Share", boost::bind(&LLPanelAvatarProfile::share, this));
 
 	mProfileMenu = LLUICtrlFactory::getInstance()->createFromFile<LLToggleableMenu>("menu_profile_overflow.xml", gMenuHolder, LLViewerMenuHolderGL::child_registry_t::instance());
 
@@ -525,6 +526,11 @@ void LLPanelAvatarProfile::pay()
 	LLAvatarActions::pay(getAvatarId());
 }
 
+void LLPanelAvatarProfile::share()
+{
+	LLAvatarActions::share(getAvatarId());
+}
+
 void LLPanelAvatarProfile::onUrlTextboxClicked(const std::string& url)
 {
 	LLWeb::loadURL(url);
diff --git a/indra/newview/llpanelavatar.h b/indra/newview/llpanelavatar.h
index a0caf0c9156dd01102014c61edc1d131672e4788..587b9cabe97be5eef24cbfaa3c4acb93caccdd6d 100644
--- a/indra/newview/llpanelavatar.h
+++ b/indra/newview/llpanelavatar.h
@@ -172,6 +172,11 @@ class LLPanelAvatarProfile
 	 */
 	void pay();
 
+	/**
+	 * opens inventory and IM for sharing items
+	 */
+	void share();
+
 	void onUrlTextboxClicked(const std::string& url);
 	void onHomepageTextboxClicked();
 	void onAddFriendButtonClick();
diff --git a/indra/newview/llpanelimcontrolpanel.cpp b/indra/newview/llpanelimcontrolpanel.cpp
index 40319d949dbbfae12508d9e4b980133919366ad7..fa6d16cfb16839689b9bf6b4412817d804efce95 100644
--- a/indra/newview/llpanelimcontrolpanel.cpp
+++ b/indra/newview/llpanelimcontrolpanel.cpp
@@ -160,13 +160,7 @@ void LLPanelIMControlPanel::onAddFriendButtonClicked()
 
 void LLPanelIMControlPanel::onShareButtonClicked()
 {
-	LLSD key;
-	LLSideTray::getInstance()->showPanel("sidepanel_inventory", key);
-
-	if (gIMMgr->hasSession(getSessionId()))
-	{
-		LLIMModel::getInstance()->addMessage(getSessionId(), SYSTEM_FROM, LLUUID::null, LLTrans::getString("share_alert"), false);
-	}
+	LLAvatarActions::share(mAvatarID);
 }
 
 void LLPanelIMControlPanel::setSessionId(const LLUUID& session_id)
diff --git a/indra/newview/llpanelpeople.cpp b/indra/newview/llpanelpeople.cpp
index 4dc88725573273b3e7655fa4843f2f04c0cfd916..c33277601081729ac45b46eb5f7b36750b92c4e1 100644
--- a/indra/newview/llpanelpeople.cpp
+++ b/indra/newview/llpanelpeople.cpp
@@ -758,7 +758,7 @@ void LLPanelPeople::updateButtons()
 	buttonSetEnabled("view_profile_btn",	item_selected);
 	buttonSetEnabled("im_btn",				multiple_selected); // allow starting the friends conference for multiple selection
 	buttonSetEnabled("call_btn",			multiple_selected);
-	buttonSetEnabled("share_btn",			item_selected && false); // not implemented yet
+	buttonSetEnabled("share_btn",			item_selected); // not implemented yet
 
 	bool none_group_selected = item_selected && selected_id.isNull();
 	buttonSetEnabled("group_info_btn", !none_group_selected);
@@ -1211,7 +1211,7 @@ void LLPanelPeople::onTeleportButtonClicked()
 
 void LLPanelPeople::onShareButtonClicked()
 {
-	// *TODO: not implemented yet
+	LLAvatarActions::share(getCurrentItemID());
 }
 
 void LLPanelPeople::onMoreButtonClicked()
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index 75e35e5221459d2534707b105d92e4315bba5c21..9e75d7853d380c3bbebcaf2f64cc0fecd3727198 100644
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -7636,15 +7636,19 @@ void LLVOAvatar::idleUpdateRenderCost()
 		return;
 	}
 
-	U32 shame = 0;
+	U32 cost = 0;
+	std::set<LLUUID> textures;
 
 	for (U8 baked_index = 0; baked_index < BAKED_NUM_INDICES; baked_index++)
 	{
 		const LLVOAvatarDictionary::BakedEntry *baked_dict = LLVOAvatarDictionary::getInstance()->getBakedTexture((EBakedTextureIndex)baked_index);
 		ETextureIndex tex_index = baked_dict->mTextureIndex;
-		if (isTextureVisible(tex_index))
+		if ((tex_index != TEX_SKIRT_BAKED) || (isWearingWearableType(WT_SKIRT)))
 		{
-			shame +=20;
+			if (isTextureVisible(tex_index))
+			{
+				cost +=20;
+			}
 		}
 	}
 
@@ -7663,20 +7667,22 @@ void LLVOAvatar::idleUpdateRenderCost()
 				const LLDrawable* drawable = attached_object->mDrawable;
 				if (drawable)
 				{
-					shame += 10;
+					cost += 10;
 					const LLVOVolume* volume = drawable->getVOVolume();
 					if (volume)
 					{
-						shame += volume->getRenderCost();
+						cost += volume->getRenderCost(textures);
 					}
 				}
 			}
 		}
 	}
 
-	setDebugText(llformat("%d", shame));
-	F32 green = 1.f-llclamp(((F32) shame-1024.f)/1024.f, 0.f, 1.f);
-	F32 red = llmin((F32) shame/1024.f, 1.f);
+	cost += textures.size() * 5;
+
+	setDebugText(llformat("%d", cost));
+	F32 green = 1.f-llclamp(((F32) cost-1024.f)/1024.f, 0.f, 1.f);
+	F32 red = llmin((F32) cost/1024.f, 1.f);
 	mText->setColor(LLColor4(red,green,0,1));
 }
 
diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp
index d9c5e932a2648f197862c5a0fd0f9e0a84fb83dd..843cba78606c57574eb4bb7c71dedd6c5d7fd0bf 100644
--- a/indra/newview/llvoavatarself.cpp
+++ b/indra/newview/llvoavatarself.cpp
@@ -318,11 +318,6 @@ BOOL LLVOAvatarSelf::buildMenus()
 
 				}
 			}
-
-			if (!attachment_found)
-			{
-				gAttachPieMenu->addSeparator();
-			}
 		}
 
 		if (gDetachBodyPartPieMenus[i])
@@ -362,11 +357,6 @@ BOOL LLVOAvatarSelf::buildMenus()
 					break;
 				}
 			}
-
-			if (!attachment_found)
-			{
-				gDetachPieMenu->addSeparator();
-			}
 		}
 	}
 
diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp
index e5531a14977512f2660b75f650fb5fba3d2ab202..1f49cd30c77835a88d86cc8cd68f0a64bdf9d1f8 100644
--- a/indra/newview/llvovolume.cpp
+++ b/indra/newview/llvovolume.cpp
@@ -2541,7 +2541,11 @@ const LLMatrix4 LLVOVolume::getRenderMatrix() const
 	return mDrawable->getWorldMatrix();
 }
 
-U32 LLVOVolume::getRenderCost() const
+// Returns a base cost and adds textures to passed in set.
+// total cost is returned value + 5 * size of the resulting set.
+// Cannot include cost of textures, as they may be re-used in linked
+// children, and cost should only be increased for unique textures  -Nyx
+U32 LLVOVolume::getRenderCost(std::set<LLUUID> &textures) const
 {
 	U32 shame = 0;
 
@@ -2574,7 +2578,7 @@ U32 LLVOVolume::getRenderCost() const
 	{
 		const LLSculptParams *sculpt_params = (LLSculptParams *) getParameterEntry(LLNetworkData::PARAMS_SCULPT);
 		LLUUID sculpt_id = sculpt_params->getSculptTexture();
-		shame += 5;
+		textures.insert(sculpt_id);
 	}
 
 	for (S32 i = 0; i < drawablep->getNumFaces(); ++i)
@@ -2583,7 +2587,7 @@ U32 LLVOVolume::getRenderCost() const
 		const LLTextureEntry* te = face->getTextureEntry();
 		const LLViewerTexture* img = face->getTexture();
 
-		shame += 5;
+		textures.insert(img->getID());
 
 		if (face->getPoolType() == LLDrawPool::POOL_ALPHA)
 		{
@@ -2633,7 +2637,7 @@ U32 LLVOVolume::getRenderCost() const
 			const LLVOVolume* child_volumep = child_drawablep->getVOVolume();
 			if (child_volumep)
 			{
-				shame += child_volumep->getRenderCost();
+				shame += child_volumep->getRenderCost(textures);
 			}
 		}
 	}
diff --git a/indra/newview/llvovolume.h b/indra/newview/llvovolume.h
index fb543efc048c6f6765228ee35ee5d7086c126cfe..6bad245e192b3b8ee35dccfd7b3d39b9f6307f00 100644
--- a/indra/newview/llvovolume.h
+++ b/indra/newview/llvovolume.h
@@ -120,7 +120,7 @@ class LLVOVolume : public LLViewerObject
 	const LLMatrix4&	getRelativeXform() const				{ return mRelativeXform; }
 	const LLMatrix3&	getRelativeXformInvTrans() const		{ return mRelativeXformInvTrans; }
 	/*virtual*/	const LLMatrix4	getRenderMatrix() const;
-				U32 	getRenderCost() const;
+				U32 	getRenderCost(std::set<LLUUID> &textures) const;
 
 	/*virtual*/ BOOL lineSegmentIntersect(const LLVector3& start, const LLVector3& end, 
 										  S32 face = -1,                        // which face to check, -1 = ALL_SIDES
diff --git a/indra/newview/llwearable.cpp b/indra/newview/llwearable.cpp
index ced0b6489667db5ba608d0c4d73b96e42525a141..d92da4ef4441eae11133b93b13da6f9ce3a23a3f 100644
--- a/indra/newview/llwearable.cpp
+++ b/indra/newview/llwearable.cpp
@@ -421,18 +421,6 @@ BOOL LLWearable::importFile( LLFILE* file )
 	// copy all saved param values to working params
 	revertValues();
 
-	// Hack pt 2. If the wearable we just loaded has definition version 24,
-	// then force a re-save of this wearable after slamming the version number to 22.
-	// This number was incorrectly incremented for internal builds before release, and
-	// this fix will ensure that the affected wearables are re-saved with the right version number.
-	// the versions themselves are compatible. This code can be removed before release.
-	if( mDefinitionVersion == 24 )
-	{
-		mDefinitionVersion = 22;
-		U32 index = gAgentWearables.getWearableIndex(this);
-		gAgentWearables.saveWearable(mType,index,TRUE);
-	}
-
 	return TRUE;
 }
 
diff --git a/indra/newview/llwearable.h b/indra/newview/llwearable.h
index 0863adb7f56fa590fa411cb3ac6555b3ed191602..43ffa124207a131cbcbfdbe5b5c307abcdb7a8d4 100644
--- a/indra/newview/llwearable.h
+++ b/indra/newview/llwearable.h
@@ -82,6 +82,8 @@ class LLWearable
 	const std::string&			getTypeName() const;
 	LLAssetType::EType			getAssetType() const;
 	LLLocalTextureObject*		getLocalTextureObject(S32 index) const;
+	S32							getDefinitionVersion() const { return mDefinitionVersion; }
+	void						setDefinitionVersion( S32 new_version ) { mDefinitionVersion = new_version; }
 
 public:
 	typedef std::vector<LLVisualParam*> visual_param_vec_t;
diff --git a/indra/newview/skins/default/xui/en/menu_profile_overflow.xml b/indra/newview/skins/default/xui/en/menu_profile_overflow.xml
index 7b52fecef713b9255d35a89f525318d76122b7a6..d0128d1c9a09a4c2f986f568f97b2c048d08b3b8 100644
--- a/indra/newview/skins/default/xui/en/menu_profile_overflow.xml
+++ b/indra/newview/skins/default/xui/en/menu_profile_overflow.xml
@@ -12,4 +12,11 @@
         <menu_item_call.on_click
          function="Profile.Pay" />
     </menu_item_call>
+    <menu_item_call
+     label="Share"
+     layout="topleft"
+     name="share">
+        <menu_item_call.on_click
+         function="Profile.Share" />
+    </menu_item_call>
 </toggleable_menu>
diff --git a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
index 73d843e6dd4821f3977d5d5b1c127bd84c4b13d3..0a5812882da60e16afcf4d1d7cfc84647d46d428 100644
--- a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
@@ -38,12 +38,12 @@
      label="Teleport"
      name="teleport_btn"
      width="100" />
-  <!--  <button
+   <button
      follows="left|top"
      height="20"
      label="Share"
      name="share_btn"
-     width="100" />-->
+     width="100" />
      <!--Removing pay button to save space - will update spec - verified by Erica/Steve -->
  <!--   <button
      follows="left|top"
diff --git a/indra/newview/skins/default/xui/en/sidepanel_inventory.xml b/indra/newview/skins/default/xui/en/sidepanel_inventory.xml
index b8b3d993bd1a1ce58a8bb542332f6b6c52bb7aa2..bb29397ef69dc5428d46902c7eb3e5d5d1078099 100644
--- a/indra/newview/skins/default/xui/en/sidepanel_inventory.xml
+++ b/indra/newview/skins/default/xui/en/sidepanel_inventory.xml
@@ -49,17 +49,6 @@
 				 name="info_btn"
 				 top="0"
 				 width="60" />
-			<button
-				 enabled="true"
-				 follows="bottom|left"
-				 font="SansSerifSmall"
-				 height="25"
-				 label="Share"
-				 layout="topleft"
-				 left_pad="5"
-				 name="share_btn"
-				 top="0"
-				 width="60" />
 			<button
 				 enabled="false"
 				 follows="bottom|left"