Markets are ending the week on a strong note today, the big S&P 500 shoving its way to new all-time highs early in Friday's session.

That's obviously a good thing for stock market investors--but it's hardly the end of the story. Even though the big market averages are hitting new high-water marks, there's a very large chunk of this market that's not participating in the upside.

For instance, while the S&P is up more than 9% year-to-date, one in three S&P 500 components is actually down in 2017. If you've owned these "toxic stocks" this year, you've had a colossal drag on your portfolio performance.

Now, as we head toward the second half of 2017, the key to beating the market isn't finding the very best stocks to own; instead, the key is just not owning the stocks that could drop further from here. To accomplish that, we're turning to the charts for a technical look at three stocks that are about to trigger sell signals (and when you should actually sell them).

Just so we're clear, the companies I'm talking about are hardly junk--many of them have very strong businesses.

But that's frankly irrelevant to what happens to their stocks; from a technical analysis standpoint, sellers are shoving around these toxic stocks right now. For that reason, fundamental investors need to decide how long they're willing to take the pain if they want to hold onto these firms in the weeks and months ahead. And for investors looking to buy one of these positions, it makes sense to wait for more favorable technical conditions (and a lower share price) before piling in.

General Electric Co.

Leading things off is $240 billion industrial giant General Electric Co. (GE) . GE is one of the laggards I mentioned earlier: shares have shed more than 12% of their market value since the start of the calendar year, which means that this blue chip stalwart is actually underperforming the rest of the S&P 500 by a huge margin.

Trouble is, shares look ready to kick off another leg of selling this summer.

GE has spent the last month forming a textbook example of a descending triangle pattern, a bearish continuation setup that's formed by horizontal support down below shares at $27.25, and downtrending resistance to the top-side. Basically, as GE bounces between those two chart lines, shares have been getting squeezed closer and closer to breakdown territory. Once shares violate $27.25 materially, GE opens up a lot more downside risk.

One of the most important technical indicators in this market is relative strength, the line down at the bottom of GE's price chart. Relative strength has been making lower highs in GE since late last fall, indicating that the underperformance continues now--as long as that's the case, it makes sense to avoid shares of GE.

Cnooc Ltd.

We're seeing the exact same price setup play out in shares of Chinese energy giant Cnooc Ltd. (CEO) right now. Like GE, Cnooc has been in sell mode in 2017, and it's been forming a descending triangle setup of its own since March. For Cnooc, the big breakdown level to watch is support down at $110.

What makes that $110 price so significant in Cnooc? It all comes down to buyers and seller.

The $110 support level is a price where there is an excess of demand of shares; in other words, it's a spot where buyers have been more eager to step in and buy than sellers have been to sell. That's what makes a breakdown below $110 so significant--the move means that sellers have absorbed all of the excess demand below that level, and downside risk is in play. Keep a close eye on this trade--shares are close to $110 as I write. 

Telefonica SA

Rounding out our list of potentially toxic trades is Telefonica SA (TEF) , a $56 billion overseas telecom giant. Unlike the other two stocks on our list, TEF has actually been rallying in 2017, up 22% since the start of the year. But shareholders might want to think about taking some of those gains off the table here: TEF looks toppy.

Telefonica has spent the past several months forming a head-and-shoulders top, a bearish reversal pattern that signals exhaustion among sellers. It's formed by two swing highs that top out at approximately the same level (the shoulders), separated by a higher high (the head). The sell signal comes on the violation of Telefonica's neckline at the $10.75 level.

Caveat emptor.

At the time of publication, author had no positions in the stocks mentioned.

More from Stocks

Stocks Slide on Renewed Trade War Concerns

Stocks Slide on Renewed Trade War Concerns

Video: Here's Where to Put Your Money Amid Trade War Fears

Video: Here's Where to Put Your Money Amid Trade War Fears

The Single Biggest Reason Trade War Fears Could Finally Topple the Stock Market

The Single Biggest Reason Trade War Fears Could Finally Topple the Stock Market

Activist-Targeted Rent-A-Center Sold to Vintage

Activist-Targeted Rent-A-Center Sold to Vintage

Ford's CEO Just Got a Badly Needed Vote of Confidence From His Boss

Ford's CEO Just Got a Badly Needed Vote of Confidence From His Boss