This study will evaluate the efficacy of ranolazine compared to placebo on duration of exercise assessed by exercise tolerance testing (ETT) at anticipated peak ranolazine plasma concentration after 12 weeks of treatment in subjects with chronic stable angina and coronary artery disease (CAD) who have a history of type 2 diabetes mellitus (T2DM). This is a randomized, double-blind, placebo-controlled, parallel group study in subjects with chronic stable angina and CAD receiving a stable dose of a single concomitant antianginal medication who also have a history of T2DM; allowed antianginals will be a beta-blocker (atenolol or metoprolol) or a calcium-channel blocker.